/*
Theme Name: FilmyFly Classic Mobile Desktop
Theme URI: https://filmy4wap.io/
Author: Custom Theme Build
Description: Compact reference-matched WordPress theme using the supplied FilmyFly website sizing and typography on desktop and mobile.
Version: 1.7.5
Requires at least: 6.0
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: filmyfly-classic
*/

/* Reference baseline: the supplied site uses Verdana-family typography,
   small base text, 60x65 movie posters, 15px movie titles and 10px badges. */
:root{
  --blue:#006699;
  --bar:#dde7f1;
  --border:#aabbcc;
  --notice:#fff3cd;
  --green:#06691F;
  --red:#C40000;
  --pink:#B000B0;
  --mustard:#8A6500;
  --blue-title:#0000CC;
  --link:#006699;
  --text:#000;
}

*{box-sizing:border-box;}
html{margin:0;padding:0;max-width:100%;}
body{
  margin:0;
  padding:0;
  background:#fff;
  color:var(--text);
  font-family:verdana,"Comic Sans MS",Helvetica,sans-serif;
  font-size:small;
  line-height:normal;
  overflow-x:hidden;
}
body.admin-bar{margin-top:0;}
body,td,th{font-size:small;}

img{border:0;vertical-align:middle;max-width:100%;height:auto;}
a{color:var(--link);text-decoration:none;}
a:hover,a:focus-visible{text-decoration:underline;}
button,input,textarea,select{font:inherit;}

/* ===== Main / global elements ===== */
main,
.site-content,
.site-header,
.footer{
  width:100%;
  min-width:0;
  max-width:100%;
  margin-left:auto;
  margin-right:auto;
}

h1{
  margin:0;
  color:#000;
  border:1px solid rgb(170,187,204);
  background:#fff;
  font-size:110%;
  padding:5px;
  font-weight:bold;
  text-align:center;
}
h2{
  margin:0;
  color:#006699;
  background:rgb(221,231,241);
  border:1px solid rgb(170,187,204);
  font-size:110%;
  padding:5px;
  font-weight:bold;
  text-align:center;
}
h2 a{color:#006699;}
h3{
  margin:0;
  color:#fff;
  background:#006699;
  padding:5px;
  font-size:110%;
  text-align:center;
  text-transform:uppercase;
}
p{padding:6px 0;margin:0;}

table{
  width:100%;
  margin:auto;
  border-collapse:collapse;
}
table tr,table th{background:#fff;}
table td{padding:5px;}

/* ===== Header ===== */
.header-banner{
  width:100%;
  height:60px;
  background:rgb(221,231,241);
  border:1px solid rgb(170,187,204);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}
.header-banner a{
  display:block;
  width:100%;
  height:100%;
  line-height:0;
  text-align:center;
}
.header-banner img{
  display:block;
  width:400px;
  height:60px;
  max-width:100%;
  margin:0 auto;
  object-fit:cover;
}

.search-strip{
  width:100%;
  min-height:28px;
  background:#006699;
  border:1px dashed #fff;
  padding:2px;
  color:#fff;
  font-weight:bold;
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}
.search-strip form{
  margin:0;
  display:flex;
  align-items:center;
  justify-content:center;
  gap:2px;
  width:100%;
}
.search-strip input[type="text"]{
  width:200px;
  max-width:62%;
  height:21px;
  padding:0 4px;
  border:1px solid #999;
  border-radius:0;
  background:#fff;
  color:#000;
  outline:0;
}
.search-strip input[type="submit"]{
  height:23px;
  padding:1px 6px;
  border:1px solid #888;
  border-radius:0;
  background:#fff;
  color:#000;
  cursor:pointer;
}

.bookmark-bar{
  position:relative;
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
  min-height:42px;
  padding:8px 44px 8px 10px;
  background:#fff3cd;
  color:#b00020;
  border:1px solid #e1a900;
  font-family:Verdana,Arial,sans-serif;
  font-size:15px;
  line-height:1.5;
  text-align:center;
  box-sizing:border-box;
}
.bookmark-bar > span{
  display:block;
  max-width:100%;
  overflow-wrap:anywhere;
}
.bookmark-bar .red{color:#b00020;font-weight:900;}
.bookmark-bar a{
  color:#006699;
  font-weight:900;
  text-decoration:underline;
}
.bookmark-close{
  position:absolute;
  top:50%;
  right:8px;
  width:27px;
  height:27px;
  padding:0;
  transform:translateY(-50%);
  background:#fff;
  color:#b00020;
  border:1px solid #d49b00;
  border-radius:50%;
  font-size:21px;
  font-weight:900;
  line-height:23px;
  cursor:pointer;
}
.bookmark-close:hover{background:#b00020;color:#fff;}
.bookmark-closing{animation:ffly-bookmark-close .11s ease forwards;}
@keyframes ffly-bookmark-close{from{opacity:1}to{opacity:0;transform:translateY(-54%);}}

/* ===== Homepage tagline / intro ===== */
.site-tagline{
  width:100%;
  min-height:30px;
  padding:5px;
  background:#fff;
  color:#000;
  text-align:center;
  font-size:110%;
  line-height:normal;
  font-weight:bold;
  border:0;
  overflow:hidden;
}

/* ===== Homepage intro ===== */
.welcome-section{
  border:1px solid #ddd;
  margin:10px 0;
  padding:13px;
  background:#fff;
}
.box-title{
  margin:0 0 7px;
  min-height:0;
  padding:5px;
  border:1px solid rgb(170,187,204);
  display:flex;
  align-items:center;
  justify-content:center;
  text-align:center;
  font-size:110%;
  line-height:1.3;
  font-weight:bold;
  background:#fff;
}
.welcome-section p{font-size:small;line-height:normal;margin:0 0 7px;}
.section-bar{
  margin:0;
  padding:5px;
  min-height:0;
  border:1px solid rgb(170,187,204);
  background:rgb(221,231,241);
  color:#006699;
  text-align:center;
  font-size:110%;
  line-height:normal;
  font-weight:bold;
}

/* ===== Movie cards — exact reference core sizes ===== */
.movie-list{width:100%;}
.movie-card{
  display:flex;
  align-items:flex-start;
  width:100%;
  min-height:0;
  margin:0;
  padding:4px;
  background:#fff;
  border-bottom:1px solid #ccc;
  overflow:hidden;
}
.movie-thumb-wrap{
  flex:0 0 60px;
  width:60px;
  height:65px;
  margin-right:5px;
  display:block;
  line-height:0;
}
.movie-thumb{
  display:block;
  width:60px !important;
  height:65px !important;
  min-width:60px;
  max-width:none !important;
  object-fit:fill;
  border:1px solid #ddd;
  border-radius:3px;
  padding:0;
  margin:0;
}
.movie-info{min-width:0;flex:1 1 auto;padding-top:0;}
.movie-title{
  display:block;
  width:100%;
  margin:0;
  font-size:15px;
  line-height:normal;
  font-weight:bold;
  overflow-wrap:anywhere;
  word-break:normal;
  text-decoration:none;
}
.movie-title.default{color:#0000CC;}
.movie-title.green{color:#06691F;}
.movie-title.pink{color:#B000B0;}
.movie-title.red{color:#C40000;}
.movie-title.gold{color:#8A6500;}
.movie-title:hover,.movie-title:focus-visible,.movie-title:active{text-decoration:underline;}
.movie-cat{
  display:inline-block;
  max-width:100%;
  margin:0;
  padding:2px 6px;
  font-size:10px;
  line-height:normal;
  font-weight:bold;
  color:#fff;
  border-radius:10px;
  vertical-align:top;
  overflow-wrap:anywhere;
}
.movie-cat.default{background:#0000CC;}
.movie-cat.green{background:#06691F;}
.movie-cat.pink{background:#B000B0;}
.movie-cat.south{background:#06691F;}
.movie-cat.web{background:#B000B0;}
.movie-cat.hollywood{background:#B000B0;}
.movie-cat.red{background:#C40000;}
.movie-cat.gold{background:#8A6500;}

/* ===== Categories ===== */
.categories-section{width:100%;}
.category-title{
  width:100% !important;
  display:flex !important;
  align-items:center !important;
  justify-content:center !important;
  text-align:center !important;
  margin:0 !important;
}
.category-list{width:100%;margin:0;padding:0;list-style:none;}
.category-list li{margin:0;padding:0;border-bottom:1px #ccc solid;}
.category-list a{
  display:block;
  background:#fcfcfc;
  color:#006699;
  border:0;
  border-bottom:0;
  padding:12px 7px;
  font-size:1.28em;
  line-height:normal;
  font-weight:bold;
  text-decoration:none;
}
.category-list a:hover,.category-list a:focus-visible{
  background:#f3f3f3;
  color:#006699;
  text-decoration:underline;
}

/* ===== Reference SEO copy ===== */
.reference-seo-copy{width:100%;margin:0;padding:0 5px;}
.reference-seo-copy p{padding:6px 0;margin:0;font-size:small;line-height:normal;}

/* ===== Tags / SEO content ===== */
.tags-bar{
  margin:0;
  padding:1px 5px;
  border:1px solid var(--border);
  background:rgb(221,231,241);
  font-size:small;
  line-height:normal;
  overflow-wrap:anywhere;
}
.tags-bar strong{color:#008000;}
.info-section{
  margin-top:10px;
  padding:13px;
  border:1px solid #ddd;
  background:#fff;
}
.info-section .box-title{
  background:rgb(221,231,241);
  margin-bottom:7px;
}
.info-section p{font-size:small;line-height:normal;margin:0 0 7px;overflow-wrap:anywhere;}
.dark-heading{
  margin:10px 0 12px;
  padding:5px;
  background:#006699;
  color:#000;
  text-align:center;
  font-size:110%;
  line-height:normal;
  font-weight:bold;
}

/* ===== Footer ===== */
.footer{margin-top:10px;text-align:center;}
.footer-note,
.footer-row{
  width:100%;
  border:1px solid var(--border);
  background:rgb(221,231,241);
  padding:5px;
  font-weight:bold;
  font-size:small;
  line-height:normal;
}
.footer-note a{color:#006699;}
.footer-links{padding:18px 8px 7px;}
.footer-links a{
  display:inline-block;
  margin:4px;
  padding:5px 9px;
  border:2px solid #0091ca;
  color:#111;
  text-decoration:none;
  font-size:small;
  background:#fff;
}
.footer-links a:nth-child(2){border-color:#3cbd46;}
.footer-links a:nth-child(3){border-color:#ddd;}
.footer-links a:nth-child(4),.footer-links a:nth-child(5){border-color:#ff4444;}
.footer-home{padding:6px 0 50px;}
.footer-home a{border-color:#777;}
.telegram{
  display:inline-block;
  margin:5px 0 4px;
  padding:5px 7px;
  border-radius:10px;
  background:#005a9c;
  color:#fff;
  text-decoration:none;
  font-weight:bold;
}

/* ===== WordPress single post ===== */
.post-wrap{
  width:100%;
  border:1px solid #ddd;
  margin:10px 0;
  padding:13px;
  background:#fff;
}
.post-title{
  margin:0 0 7px;
  padding:5px;
  background:rgb(221,231,241);
  font-size:110%;
  line-height:1.3;
  text-align:center;
  font-weight:bold;
  overflow-wrap:anywhere;
}
.post-meta{display:none !important;}
.post-featured{
  display:block;
  width:auto;
  max-width:280px;
  height:auto;
  margin:0 auto 10px;
  border:0;
  object-fit:contain;
}
.post-content{
  font-size:small;
  line-height:normal;
  overflow-wrap:anywhere;
}
.post-content > :first-child{margin-top:0;}
.post-content h2,
.post-content h3{
  background:#006699;
  color:#fff;
  border:0;
  padding:5px;
  font-size:110%;
  text-align:center;
}
/* Keep WordPress emoji/smiley images inline. They are UI glyphs, not screenshots. */
.post-content img.wp-smiley,
.post-content img.emoji,
.post-content img[class*="emoji"],
.post-content img[class*="smiley"]{
  display:inline !important;
  width:1em !important;
  height:1em !important;
  max-width:none !important;
  margin:0 .15em !important;
  vertical-align:-.15em !important;
  object-fit:contain !important;
}

.post-content img{
  display:block;
  width:100%;
  max-width:100% !important;
  height:auto;
  margin:10px auto;
  object-fit:contain;
}
.post-content img:not(.ffly-post-poster){
  width:100vw !important;
  max-width:100vw !important;
  margin-left:calc(50% - 50vw) !important;
  margin-right:calc(50% - 50vw) !important;
}
/* Reference main poster size: max 280px and centered on both desktop/mobile. */
.post-content img.ffly-post-poster{
  width:280px !important;
  max-width:280px !important;
  margin:0 auto 10px !important;
}
/* Reference screenshot/article images: full-viewport bleed on both desktop and mobile,
   while preserving natural image height. The main poster remains compact and centered. */
.post-content img.ffly-post-screenshot,
.post-content .ss img,
.post-content .showimage img,
.post-content .article img{
  display:block;
  width:100vw !important;
  max-width:100vw !important;
  height:auto !important;
  margin:10px 0 10px calc(50% - 50vw) !important;
  object-fit:contain !important;
}
.post-content figure{max-width:100%;margin:10px auto;}
.post-content figure.ffly-screenshot{width:100vw;max-width:100vw;margin-left:calc(50% - 50vw);margin-right:calc(50% - 50vw);}
.post-content figure.ffly-screenshot img{width:100vw !important;max-width:100vw !important;height:auto !important;margin:0 !important;object-fit:contain !important;}
.post-content table{max-width:100%;width:100%;border-collapse:collapse;table-layout:auto;}
.post-content td,.post-content th{border:1px solid #ccc;padding:5px;}
.post-content pre,.post-content iframe,.post-content video,.post-content embed{max-width:100%;}
.post-content ul,.post-content ol{padding-left:24px;}
.post-content .aligncenter{margin-left:auto;margin-right:auto;}

/* ===== Reference-style single-post presentation =====
   These rules intentionally affect only single posts so the homepage stays unchanged. */
.single-post .post-wrap{background:#fff;}
.single-post .post-content{font-size:small;line-height:normal;}
.single-post .post-content .post-file-info-heading,
.single-post .post-content .post-file-info-heading h1,
.single-post .post-content .post-file-info-heading h2,
.single-post .post-content .post-file-info-heading h3{
  display:block;
  width:100%;
  min-height:0;
  margin:0 !important;
  padding:5px !important;
  background:#dde7f1 !important;
  border:1px solid #aabbcc !important;
  color:#c40000 !important;
  font-size:110% !important;
  font-weight:bold;
  line-height:normal !important;
  text-align:center;
  overflow:visible;
}
.single-post .post-content .post-download-heading,
.single-post .post-content .post-screenshot-heading,
.single-post .post-content .post-related-heading{
  display:block;
  width:100%;
  min-height:0;
  margin:0 !important;
  padding:5px !important;
  background:#006699 !important;
  border:0 !important;
  color:#fff !important;
  font-size:110% !important;
  font-weight:bold;
  line-height:normal !important;
  text-align:center;
}
.post-official-link{
  display:block;
  width:100%;
  margin:4px 0 6px !important;
  padding:0 !important;
  text-align:center !important;
  font-size:small !important;
  line-height:normal !important;
  white-space:nowrap;
  overflow-wrap:normal;
}
.single-post .post-official-link{
  box-sizing:border-box;
}
.post-official-link br{display:none !important;}
.post-official-link center{display:inline !important;}
.post-official-link *{line-height:normal !important;}
.post-official-link strong{font-weight:bold;}
.post-official-link a{font-weight:bold;}
.single-post .post-content img.wp-smiley,
.single-post .post-content img.emoji,
.single-post .post-content img[class*="emoji"],
.single-post .post-content img[class*="smiley"]{
  display:inline !important;
  width:1em !important;
  height:1em !important;
  max-width:none !important;
  margin:0 .15em !important;
  vertical-align:-.15em !important;
  object-fit:contain !important;
}

.single-post .post-content .post-file-row{
  display:block;
  width:100%;
  margin:0 !important;
  padding:5px !important;
  background:#fff !important;
  border-bottom:1px solid #ccc !important;
  box-sizing:border-box;
  font-size:small;
  line-height:normal;
}
.wp-block-button__link{background:#006699;}

/* ===== Related movies ===== */
.related-title{
  margin:0;
  min-height:0;
  padding:5px;
  background:#006699;
  border-color:#006699;
  color:#fff;
  font-size:110%;
  line-height:normal;
  font-weight:bold;
  text-align:center;
  text-decoration:none;
}
.related-title:hover,.related-title:focus-visible{color:#fff;text-decoration:none;}

/* ===== Pagination ===== */
.pagination-wrap{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:4px;
  text-align:center;
  padding:18px 0 20px;
}
.pagination-wrap a{
  display:inline-block;
  margin:2px 1px 5px;
  padding:5px 8px;
  border:1px #000 solid;
  border-radius:3px;
  background:#555;
  color:#fff;
  font-weight:bold;
  text-shadow:1px 1px 1px #000;
  text-decoration:none;
  font-size:small;
  line-height:normal;
}
.pagination-wrap a:hover,.pagination-wrap a:focus-visible{background:#111;color:#f5f5f5;text-decoration:none;}

/* ===== Click/tap effect retained ===== */
.ffly-clickable,
.bookmark-close,
.search-strip input[type="submit"]{
  transition:transform .12s ease,box-shadow .12s ease,filter .12s ease,opacity .12s ease;
  -webkit-tap-highlight-color:transparent;
}
.ffly-clickable:active,
.ffly-clickable.ffly-clicked,
.bookmark-close:active,
.bookmark-close.ffly-clicked,
.search-strip input[type="submit"]:active,
.search-strip input[type="submit"].ffly-clicked{
  transform:scale(.97);
  filter:brightness(.96);
  box-shadow:0 2px 5px rgba(0,0,0,.16) inset;
}

/* ===== Utility ===== */
.screen-reader-text{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0;}
.alignleft{float:left;margin:0 1em 1em 0;}
.alignright{float:right;margin:0 0 1em 1em;}
.aligncenter{display:block;margin-left:auto;margin-right:auto;}

/* 404/search utility blocks, kept compact and compatible with the reference. */
.error-404-page{padding:18px 8px 20px;text-align:center;background:#f8fbfd;border-bottom:1px solid #ccc;}
.error-404-code{color:#006699;font-size:46px;font-weight:bold;line-height:1;}
.error-404-page p{max-width:560px;margin:0 auto;padding:10px 4px 12px;color:#222;line-height:1.45;}
.error-404-actions{display:flex;flex-wrap:wrap;justify-content:center;gap:7px;}
.error-404-button{display:inline-block;min-width:132px;padding:8px 10px;border:1px solid #006699;border-radius:4px;background:#006699;color:#fff;font-weight:bold;text-align:center;text-decoration:none;}
.error-404-button:hover{color:#fff;text-decoration:none;opacity:.9;}
.error-404-button-alt{background:#fff;color:#006699;}
.error-404-button-alt:hover{color:#006699;}
.search-empty-state{margin:0;padding:18px 8px 20px;text-align:center;background:#f8fbfd;border-bottom:1px solid #ccc;}
.search-empty-icon{display:inline-flex;align-items:center;justify-content:center;width:42px;height:42px;margin-bottom:8px;border-radius:50%;background:#006699;color:#fff;font-size:28px;font-weight:bold;line-height:1;}
.search-empty-state p{max-width:620px;margin:0 auto;padding:10px 4px 12px;color:#222;line-height:1.45;}
.search-empty-form{display:flex;justify-content:center;gap:6px;width:100%;max-width:560px;margin:0 auto 10px;}
.search-empty-form input[type="text"]{flex:1 1 auto;min-width:0;padding:7px;border:1px solid #aabbcc;}
.search-empty-form input[type="submit"]{padding:7px 10px;border:1px solid #006699;background:#006699;color:#fff;font-weight:bold;}

/* The reference keeps the same core typography at all viewport widths.
   Only overflow/fitting behavior changes on narrow screens. */
@media (max-width:600px){
  .single-post .post-official-link{
    white-space:normal;
    overflow-wrap:anywhere;
    padding:0 6px !important;
  }
  .header-banner img{
    width:400px;
    max-width:100%;
    height:auto;
    object-fit:cover;
  }
  .search-strip input[type="text"]{
    width:200px;
    max-width:58%;
  }
  .site-tagline{
    white-space:normal;
  }
  .bookmark-bar{
    min-height:6px;
    padding:1px 40px 1px 8px;
    font-size:14px;
    line-height:normal;
  }
  .welcome-section{
    margin:10px 4px;
    padding:13px;
  }
  .movie-card{
    padding:4px;
  }
  .movie-thumb-wrap{
    flex-basis:60px;
    width:60px;
    min-width:60px;
  }
  .movie-title{
    font-size:15px;
  }
  .movie-cat{
    font-size:10px;
  }
  .category-list a{
    padding:12px 7px;
  }
  .info-section{
    margin-top:10px;
    padding:13px;
  }
  .post-wrap{
    margin:6px 0;
    padding:0;
  }
  .post-featured,
  .post-content img.ffly-post-poster{
    width:min(408px,calc(100vw - 48px)) !important;
    max-width:min(408px,calc(100vw - 48px)) !important;
    height:auto !important;
    margin-left:auto !important;
    margin-right:auto !important;
  }
  .post-content img.ffly-post-screenshot,
  .post-content .ss img,
  .post-content .showimage img,
  .post-content .article img,
  .post-content figure.ffly-screenshot img{
    width:100vw !important;
    max-width:100vw !important;
    height:auto !important;
    margin-left:calc(50% - 50vw) !important;
    margin-right:calc(50% - 50vw) !important;
  }
  .post-content table{
    table-layout:fixed;
  }
  .post-content td,.post-content th{
    word-break:break-word;
    overflow-wrap:anywhere;
  }
}

@media (max-width:360px){
  .search-strip input[type="text"]{max-width:55%;}
  .bookmark-bar{padding-right:38px;}
  .movie-title{font-size:15px;}
}

/* ===== Reference feature parity: footer button system / Android banner ===== */
.footer-links{display:flex;flex-wrap:wrap;justify-content:center;align-items:center;gap:0;padding:18px 8px 7px;}
.footer-links .button,
.footer-home .button{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-width:48px;
  min-height:48px;
  margin:0 2px;
  padding:0 8px;
  border:none;
  background-color:transparent;
  color:white;
  cursor:pointer;
  font-size:12px;
  text-align:center;
  text-decoration:none;
  line-height:18px;
  isolation:isolate;
  box-sizing:border-box;
}
.footer-links .button::before,
.footer-home .button::before{
  content:"";
  position:absolute;
  inset:11px 0;
  background:#4caf50;
  z-index:-1;
}
.footer-links .button1,.footer-links .button2,.footer-links .button3,.footer-links .button4,.footer-links .button5,
.footer-home .button5{color:#000;}
.footer-links .button1::before{background:#fff;border:2px solid #4caf50;}
.footer-links .button2::before{background:#fff;border:2px solid #008cba;}
.footer-links .button3::before{background:#fff;border:2px solid #f44336;}
.footer-links .button4::before{background:#fff;border:2px solid #e7e7e7;}
.footer-links .button5::before,.footer-home .button5::before{background:#fff;border:2px solid #555;}
.footer-links .button:hover,.footer-home .button:hover{color:#000;text-decoration:underline;}
.android-banner{display:none;width:100%;overflow:hidden;margin:4px 0;}
.android-banner img{display:block;width:100%;height:auto;border:0;}
@media (max-width:600px){
  .footer-links{padding-left:4px;padding-right:4px;}
  .footer-links .button,.footer-home .button{font-size:12px;min-height:48px;padding:0 6px;}
}
