/* =================================================================
   Popcorn Studio - styles.css
   Palette: Clean Tech Blue.  Change colors in :root below.
   ================================================================= */

:root {
  /* --- Brand palette (edit here to recolor the whole site) --- */
  --bg: #ffffff;
  --surface: #f4f7fb;
  --surface-2: #eaf1fa;
  --text: #0a1a2f;
  --muted: #51637a;
  --accent: #1e88e5;
  --accent-hover: #1668b8;
  --accent-2: #22d3ee;
  --border: #e1e8f1;
  --dark: #0a1a2f;

  /* --- Typography --- */
  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  /* --- Layout --- */
  --maxw: 1160px;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(10, 26, 47, 0.06), 0 2px 8px rgba(10, 26, 47, 0.05);
  --shadow-md: 0 8px 30px rgba(10, 26, 47, 0.10);
  --shadow-lg: 0 20px 50px rgba(10, 26, 47, 0.18);
  --header-h: 70px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ----------------------------- Reset --------------------------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }
body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.65;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; padding: 0; }
button { font: inherit; cursor: pointer; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; font-weight: 800; }

/* --------------------------- Helpers --------------------------- */
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 1100;
  background: var(--accent); color: #fff; padding: 10px 16px;
  border-radius: var(--radius-sm); transition: top .2s var(--ease);
}
.skip-link:focus { top: 12px; }

.eyebrow {
  text-transform: uppercase; letter-spacing: 0.16em; font-size: 0.78rem;
  font-weight: 700; color: var(--muted); margin-bottom: 14px;
}
.eyebrow--accent { color: var(--accent); }

.section { padding: clamp(64px, 9vw, 116px) 0; }
.section--surface { background: var(--surface); }
.section__title { font-size: clamp(1.7rem, 4vw, 2.6rem); }
.section__sub { color: var(--muted); max-width: 60ch; margin-top: 14px; font-size: 1.05rem; }
.section__head { max-width: 720px; margin: 0 auto clamp(34px, 5vw, 56px); text-align: center; }
.section__head .section__sub { margin-left: auto; margin-right: auto; }

/* --------------------------- Buttons --------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 24px; border-radius: 999px; font-weight: 600; font-size: 0.98rem;
  border: 1.5px solid transparent; transition: transform .18s var(--ease), background .2s var(--ease), box-shadow .2s var(--ease), color .2s var(--ease);
  white-space: nowrap;
}
.btn--primary { background: var(--accent); color: #fff; box-shadow: 0 8px 20px rgba(30, 136, 229, 0.28); }
.btn--primary:hover { background: var(--accent-hover); transform: translateY(-2px); }
.btn--ghost { background: transparent; color: var(--text); border-color: var(--border); }
.btn--ghost:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.btn--sm { padding: 9px 18px; font-size: 0.9rem; }
.btn--lg { padding: 15px 30px; font-size: 1.05rem; }

/* --------------------------- Header ---------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: saturate(160%) blur(12px);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: box-shadow .25s var(--ease), border-color .25s var(--ease), background .25s var(--ease);
}
.site-header.is-scrolled { box-shadow: var(--shadow-sm); border-bottom-color: var(--border); }
.header__inner { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.brand__logo { height: 38px; width: auto; }

.nav { display: flex; align-items: center; }
.nav__menu { display: flex; align-items: center; gap: 28px; }
.nav__menu a:not(.btn) { color: var(--muted); font-weight: 500; position: relative; padding: 6px 0; transition: color .2s var(--ease); }
.nav__menu a:not(.btn):hover, .nav__menu a:not(.btn).is-active { color: var(--text); }
.nav__menu a:not(.btn).is-active::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 2px;
  background: var(--accent); border-radius: 2px;
}

.nav__toggle {
  display: none; flex-direction: column; gap: 5px; width: 44px; height: 44px;
  background: transparent; border: none; align-items: center; justify-content: center;
}
.nav__toggle span { width: 24px; height: 2px; background: var(--text); border-radius: 2px; transition: transform .25s var(--ease), opacity .2s var(--ease); }
.nav__toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav__toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------------------------- Hero ----------------------------- */
.hero { position: relative; min-height: calc(100vh - var(--header-h)); display: flex; align-items: center; padding: 80px 0; overflow: hidden; }
.hero__bg { position: absolute; inset: 0; z-index: -1; }
.hero__bg img { width: 100%; height: 100%; object-fit: cover; }
.hero__overlay {
  position: absolute; inset: 0;
  background: linear-gradient(105deg, rgba(10, 26, 47, 0.88) 0%, rgba(10, 26, 47, 0.65) 45%, rgba(10, 26, 47, 0.25) 100%);
}
.hero__content { color: #fff; max-width: 760px; }
.hero .eyebrow { color: var(--accent-2); }
.hero__title { font-size: clamp(2.2rem, 6vw, 4rem); margin-bottom: 20px; }
.hero__lead { font-size: clamp(1.05rem, 2.2vw, 1.3rem); color: rgba(255, 255, 255, 0.86); max-width: 60ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 34px; }
.hero .btn--ghost { color: #fff; border-color: rgba(255, 255, 255, 0.4); }
.hero .btn--ghost:hover { border-color: #fff; color: #fff; background: rgba(255, 255, 255, 0.08); }
.hero__badges { display: flex; flex-wrap: wrap; gap: 10px 12px; margin-top: 40px; }
.hero__badges li {
  font-size: 0.82rem; font-weight: 600; letter-spacing: 0.02em;
  padding: 7px 14px; border-radius: 999px;
  background: rgba(255, 255, 255, 0.10); border: 1px solid rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.92); backdrop-filter: blur(4px);
}

/* ---------------------------- About ---------------------------- */
.about { display: grid; grid-template-columns: 1fr; gap: clamp(34px, 5vw, 60px); align-items: center; }
.about__text p { color: var(--muted); margin-top: 16px; max-width: 62ch; }
.about__text strong { color: var(--text); }
.about__stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.about__stats li {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 26px 20px; text-align: center; box-shadow: var(--shadow-sm);
}
.section--surface .about__stats li { background: #fff; }
.stat__value { display: block; font-size: clamp(1.8rem, 4vw, 2.4rem); font-weight: 800; color: var(--accent); letter-spacing: -0.03em; }
.stat__label { display: block; margin-top: 8px; font-size: 0.9rem; color: var(--muted); }

/* ---------------------------- Grids ---------------------------- */
.grid { display: grid; gap: 22px; }
.grid--cards { grid-template-columns: 1fr; }
.grid--features { grid-template-columns: 1fr; }

/* ---------------------------- Cards ---------------------------- */
.card {
  background: var(--bg); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 30px 28px; box-shadow: var(--shadow-sm);
  transition: transform .22s var(--ease), box-shadow .22s var(--ease), border-color .22s var(--ease);
  position: relative; overflow: hidden;
}
.card::before {
  content: ""; position: absolute; left: 0; top: 0; height: 4px; width: 100%;
  background: linear-gradient(90deg, var(--accent), var(--accent-2));
  transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: transparent; }
.card:hover::before { transform: scaleX(1); }
.card__title { font-size: 1.22rem; margin-bottom: 12px; font-weight: 700; }
.card p { color: var(--muted); font-size: 0.98rem; }

/* --------------------------- Features -------------------------- */
.feature { padding: 30px 26px; border-radius: var(--radius); background: var(--bg); border: 1px solid var(--border); box-shadow: var(--shadow-sm); transition: transform .22s var(--ease), box-shadow .22s var(--ease); }
.feature:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); }
.feature__icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 56px; height: 56px; border-radius: 14px; margin-bottom: 18px;
  background: linear-gradient(135deg, rgba(30, 136, 229, 0.12), rgba(34, 211, 238, 0.16));
  color: var(--accent);
}
.feature__icon svg { width: 28px; height: 28px; }
.feature__title { font-size: 1.15rem; margin-bottom: 10px; font-weight: 700; }
.feature p { color: var(--muted); font-size: 0.97rem; }

/* --------------------------- Gallery --------------------------- */
.gallery__filters { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: 34px; }
.filter {
  padding: 9px 20px; border-radius: 999px; border: 1.5px solid var(--border);
  background: #fff; color: var(--muted); font-weight: 600; font-size: 0.92rem;
  transition: all .2s var(--ease);
}
.filter:hover { border-color: var(--accent); color: var(--accent); }
.filter.is-active { background: var(--accent); border-color: var(--accent); color: #fff; }

.gallery__grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.gallery__item {
  padding: 0; border: none; background: var(--surface-2); border-radius: var(--radius);
  overflow: hidden; aspect-ratio: 4 / 3; position: relative; box-shadow: var(--shadow-sm);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), opacity .3s var(--ease);
}
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s var(--ease); }
.gallery__item::after {
  content: "View"; position: absolute; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(10, 26, 47, 0.55); color: #fff; font-weight: 600; letter-spacing: 0.04em;
  opacity: 0; transition: opacity .25s var(--ease);
}
.gallery__item:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.gallery__item:hover img { transform: scale(1.06); }
.gallery__item:hover::after, .gallery__item:focus-visible::after { opacity: 1; }
.gallery__item.is-hidden { display: none; }

/* --------------------------- Contact --------------------------- */
.section--contact { background: var(--dark); color: #fff; }
.contact { display: grid; grid-template-columns: 1fr; gap: clamp(34px, 5vw, 56px); align-items: start; }
.section--contact .eyebrow--accent { color: var(--accent-2); }
.section--contact .section__sub { color: rgba(255, 255, 255, 0.72); }
.contact__intro .btn { margin-top: 28px; }
.contact__details { display: grid; gap: 22px; }
.contact__details li { display: grid; gap: 4px; padding-bottom: 18px; border-bottom: 1px solid rgba(255, 255, 255, 0.12); }
.contact__label { font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.14em; color: var(--accent-2); font-weight: 700; }
.contact__details a:hover { color: var(--accent-2); }
.social { display: flex; flex-wrap: wrap; gap: 18px; }
.social a { color: rgba(255, 255, 255, 0.9); font-weight: 500; }

/* ---------------------------- Footer --------------------------- */
.site-footer { background: #06121f; color: rgba(255, 255, 255, 0.7); padding: 40px 0; }
.footer__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.footer__brand { font-weight: 800; color: #fff; font-size: 1.05rem; }
.footer__brand span { color: var(--accent-2); font-weight: 600; }
.footer__nav { display: flex; flex-wrap: wrap; gap: 22px; }
.footer__nav a { color: rgba(255, 255, 255, 0.7); font-size: 0.92rem; }
.footer__nav a:hover { color: #fff; }
.footer__copy { width: 100%; font-size: 0.85rem; color: rgba(255, 255, 255, 0.45); border-top: 1px solid rgba(255, 255, 255, 0.1); padding-top: 18px; }

/* --------------------------- Lightbox -------------------------- */
.lightbox {
  position: fixed; inset: 0; z-index: 2000; display: flex; align-items: center; justify-content: center;
  background: rgba(6, 18, 31, 0.92); padding: 5vmin;
  opacity: 0; visibility: hidden; transition: opacity .25s var(--ease), visibility .25s var(--ease);
}
.lightbox.is-open { opacity: 1; visibility: visible; }
.lightbox__figure { max-width: 92vw; max-height: 86vh; margin: 0; text-align: center; }
.lightbox__img { max-width: 92vw; max-height: 78vh; border-radius: var(--radius-sm); box-shadow: var(--shadow-lg); }
.lightbox__caption { color: rgba(255, 255, 255, 0.85); margin-top: 14px; font-size: 0.95rem; }
.lightbox__close, .lightbox__nav {
  position: absolute; background: rgba(255, 255, 255, 0.12); color: #fff; border: none;
  width: 52px; height: 52px; border-radius: 50%; font-size: 1.6rem; line-height: 1;
  display: flex; align-items: center; justify-content: center; transition: background .2s var(--ease), transform .2s var(--ease);
}
.lightbox__close:hover, .lightbox__nav:hover { background: rgba(255, 255, 255, 0.25); }
.lightbox__close { top: 22px; right: 22px; }
.lightbox__nav { top: 50%; transform: translateY(-50%); }
.lightbox__nav:hover { transform: translateY(-50%) scale(1.08); }
.lightbox__nav--prev { left: 18px; }
.lightbox__nav--next { right: 18px; }

/* ------------------------ Reveal animation --------------------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

/* --------------------------- Focus ----------------------------- */
:focus-visible { outline: 3px solid var(--accent-2); outline-offset: 3px; border-radius: 4px; }

/* ======================= Responsive ============================ */
@media (min-width: 640px) {
  .gallery__grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 760px) {
  .about { grid-template-columns: 1.3fr 1fr; }
  .contact { grid-template-columns: 1.2fr 1fr; }
}
@media (min-width: 860px) {
  .grid--cards { grid-template-columns: repeat(2, 1fr); }
  .grid--features { grid-template-columns: repeat(2, 1fr); }
  .gallery__grid { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1080px) {
  .grid--cards { grid-template-columns: repeat(3, 1fr); }
  .grid--features { grid-template-columns: repeat(4, 1fr); }
}

/* ---- Mobile navigation (max-width 859px) ---- */
@media (max-width: 859px) {
  .nav__toggle { display: flex; }
  .nav__menu {
    position: fixed; inset: var(--header-h) 0 auto 0;
    flex-direction: column; align-items: stretch; gap: 4px;
    background: #fff; padding: 18px 22px 26px; border-bottom: 1px solid var(--border);
    box-shadow: var(--shadow-md);
    transform: translateY(-12px); opacity: 0; pointer-events: none;
    transition: transform .25s var(--ease), opacity .25s var(--ease);
  }
  .nav__menu.is-open { transform: none; opacity: 1; pointer-events: auto; }
  .nav__menu li { width: 100%; }
  .nav__menu a:not(.btn) { display: block; padding: 12px 4px; border-bottom: 1px solid var(--border); }
  .nav__menu a:not(.btn).is-active::after { display: none; }
  .nav__menu .btn { width: 100%; margin-top: 10px; }
}

/* --------------- Reduced motion preference ---------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
}
