/* ==========================================================
   CeilCraft Gypsum Board — layout matched to the client's reference site
   (white header, stacked navy sections, yellow accents, system font)
   Dark = default look. Light mode overrides the variables at the bottom.
   ========================================================== */
:root {
  --page: #ffffff;
  --ink: #111827;
  --navy: #020617;          /* section background */
  --navy-2: #0b1120;        /* inner cards */
  --navy-3: #0a0f1f;        /* photo frame */
  --line: rgba(148, 163, 184, .18);
  --yellow: #facc15;
  --cream: #fefce8;
  --box-ink: #ffffff;       /* headings in sections */
  --h2: #f9fafb;
  --ink-soft: #e5e7eb;      /* body text in sections */
  --muted-2: #94a3b8;
  --accent-text: var(--yellow);
  --accent-line: rgba(250, 204, 21, .6);
  --pill-bg: rgba(250, 204, 21, .06);
  --font: -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto, "Helvetica Neue", Tahoma, Arial, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--page); color: var(--ink); font: 400 16px/1.6 var(--font); }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { margin: 0; }
p { margin: 0; }
.wrap { width: min(1240px, 100%); margin-inline: auto; padding-inline: 20px; }
.center { text-align: center; }
.yellow { color: var(--accent-text); }
.muted { color: var(--muted-2); }
.skip { position: absolute; inset-inline-start: -999px; top: 8px; background: var(--yellow); padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { inset-inline-start: 8px; }

/* ---------- Header ---------- */
.site-header { background: #fff; border-bottom: 1px solid #e5e7eb; position: relative; z-index: 50; }
.site-header__inner { display: flex; align-items: center; gap: 20px; min-height: 80px; }
.brand { font-weight: 600; font-size: 26px; line-height: 1.2; color: var(--ink); text-decoration: none; }
.phone-pill { display: grid; place-items: center; width: 80px; height: 46px; border-radius: 999px; background: var(--yellow); text-decoration: none; font-size: 20px; flex: none; }
.phone-pill:hover { filter: brightness(.95); }
.site-nav { margin-inline-start: auto; }
.site-nav > ul { display: flex; align-items: center; list-style: none; margin: 0; padding: 0; }
.site-nav a { display: block; padding: 0 16px; line-height: 80px; text-decoration: none; color: #374151; font-size: 16px; }
.site-nav a:hover, .site-nav a.is-active { color: var(--yellow); }
.site-nav .lang a, .theme-btn { line-height: 1; border: 1px solid #e5e7eb; border-radius: 8px; padding: 8px 12px; font-size: 14px; margin-inline-start: 8px; color: #374151; background: #fff; }
.theme-btn { display: grid; place-items: center; width: 38px; height: 34px; padding: 0; cursor: pointer; font-size: 16px; margin-inline-start: 6px; }
.site-nav .lang a:hover, .theme-btn:hover { border-color: var(--yellow); color: #374151; }
.theme-btn .ico-moon, [data-theme="light"] .theme-btn .ico-sun { display: none; }
[data-theme="light"] .theme-btn .ico-moon { display: inline; }
.has-sub { position: relative; display: flex; align-items: center; }
.has-sub > a { padding-inline-end: 4px; }
.sub-btn { background: none; border: 0; padding: 4px 8px 4px 4px; color: #374151; cursor: pointer; display: grid; place-items: center; }
[dir="ltr"] .sub-btn { padding: 4px 4px 4px 8px; }
.sub { list-style: none; margin: 0; padding: 6px 0; position: absolute; top: 100%; inset-inline-start: 0; min-width: 240px; background: #fff;
  border: 1px solid #e5e7eb; border-top: 2px solid var(--yellow); box-shadow: 0 10px 24px rgba(0,0,0,.1); opacity: 0; visibility: hidden; transition: .15s; z-index: 60; }
.has-sub:hover .sub, .has-sub:focus-within .sub, .has-sub.is-open .sub { opacity: 1; visibility: visible; }
.sub a { line-height: 1.4; padding: 10px 18px; font-size: 15px; }
.menu-btn { display: none; width: 44px; height: 44px; background: none; border: 0; cursor: pointer; padding: 10px; }
.menu-btn span { display: block; height: 2px; background: #1f2937; margin: 5px 0; border-radius: 2px; transition: .2s; }

/* ---------- Sections ---------- */
main.wrap { padding-top: 24px; padding-bottom: 24px; }
.box { background: var(--navy); color: var(--box-ink); border-radius: 18px; padding: 20px 14px; margin: 0 auto 24px; max-width: 1200px; text-align: center; }
.box.hero { border-radius: 16px; padding: 22px 14px; }
.box--start { text-align: start; }
.box h1 { font-size: 20px; line-height: 28px; font-weight: 600; margin-bottom: 10px; color: var(--box-ink); }
.box h2 { font-size: 18px; line-height: 23.4px; font-weight: 600; margin-bottom: 10px; color: var(--h2); }
.box p, .box .intro { font-size: 14px; line-height: 25.2px; color: var(--ink-soft); }
.box .intro { margin-bottom: 14px; }
.box .intro a, .box p a { color: var(--accent-text); font-weight: 700; text-decoration: none; }
.box .note { color: var(--ink-soft); font-size: 13px; margin: 14px 0 0; }
.box .note a { color: var(--accent-text); }
.crumbs { font-size: 12px; color: var(--muted-2); margin-bottom: 8px; }
.crumbs a { color: var(--muted-2); text-decoration: none; }
.crumbs a:hover, .crumbs span { color: var(--accent-text); }

.badges { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 2px 0 16px; }
.badge { background: var(--navy-2); border: 1px solid rgba(250, 204, 21, .55); color: var(--accent-text); border-radius: 999px; padding: 6px 12px; font-weight: 700; font-size: 13px; line-height: 22px; }

.btns { display: grid; gap: 10px; justify-items: center; margin-top: 4px; }
.btns--inline { display: flex; flex-wrap: wrap; justify-content: center; margin-top: 16px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 4px; min-height: 44px; padding: 10px 22px; border-radius: 999px;
  font: 700 14px/1.2 var(--font); text-decoration: none; cursor: pointer; border: 1px solid transparent; transition: filter .15s, background .15s; text-align: center; }
.btns:not(.btns--inline) .btn { width: min(360px, 100%); }
.btn--yellow { background: var(--yellow); color: #111827; }
.btn--yellow:hover { filter: brightness(.94); }
.btn--outline { border-color: var(--accent-line); color: var(--accent-text); background: transparent; min-height: 46px; }
.btn--outline:hover { background: var(--pill-bg); }
.btn--auto { width: auto; margin-top: 16px; }

/* ---------- Cards ---------- */
.grid { display: grid; gap: 10px; margin: 4px auto 0; max-width: 1136px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.card { display: block; text-decoration: none; }
.card .icon { display: block; font-size: 26px; line-height: 44px; }
.card h3 { font-size: 14px; line-height: 23.8px; font-weight: 700; margin-bottom: 4px; }
.card p { font-size: 12px; line-height: 19.2px; }
.cards-cream .card { background: var(--cream); border-radius: 16px; padding: 12px 8px; color: #0f172a; }
.cards-cream .card h3 { color: #0f172a; }
.cards-cream .card p { color: #4b5563; }
.cards-cream a.card:hover { background: #fef9c3; }
.cards-dark .card { background: var(--navy-2); border: 1px solid var(--line); border-radius: 14px; padding: 12px 10px; color: var(--h2); }
.cards-dark .card h3 { color: var(--h2); }
.cards-dark .card h3.yellow { color: var(--accent-text); font-size: 15px; }
.cards-dark .card p { color: var(--ink-soft); }
.cards-dark a.card:hover { border-color: var(--accent-line); }
.align-start .card { text-align: start; padding: 14px 16px; }
.cards-cream.align-start .card { padding: 14px 16px; }
.grid--2 > :last-child:nth-child(odd) { grid-column: 1 / -1; width: calc(50% - 5px); justify-self: center; }

/* ---------- Inner box, lists, steps ---------- */
.inner { background: var(--navy-2); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; margin: 6px auto 0; max-width: 1136px; text-align: start; }
.inner.center { text-align: center; }
.inner p + p, .inner p + ul, .inner p + ol, .inner ul + p, .inner ol + p { margin-top: 10px; }
.inner--narrow { max-width: 520px; }
.steps, .bullets { margin: 0; padding-inline-start: 22px; color: var(--ink-soft); font-size: 14px; line-height: 27px; }
.bullets li::marker { color: var(--ink-soft); }
.lead-in { color: var(--accent-text); }
.inner .muted { font-size: 13px; color: var(--ink-soft); }
.inner .muted a { color: var(--accent-text); }

/* light (white) section — partitions page "what is a partition" */
.box--light { background: #f9fafb; color: var(--ink); border: 1px solid #e5e7eb; }
.box--light h2 { color: var(--ink); }
.box--light p { color: #1f2937; text-align: start; }
.box--light p + p { margin-top: 10px; }

/* ---------- Strips (areas pills, other services, link rows) ---------- */
.strip { background: var(--navy-2); border-radius: 14px; padding: 16px 14px; margin: 0 auto 24px; max-width: 1200px; text-align: center; color: var(--box-ink); }
.strip__title { font-size: 15px; font-weight: 600; color: var(--h2); margin-bottom: 12px; }
.strip__label { font-size: 13px; color: var(--ink-soft); margin-bottom: 10px; }
.strip__more { font-size: 13px; color: var(--ink-soft); margin-top: 12px; }
.strip__more a { color: var(--accent-text); font-weight: 700; text-decoration: none; }
.pills { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.pill { border: 1px solid rgba(250, 204, 21, .4); background: var(--pill-bg); color: var(--accent-text); padding: 9px 16px; border-radius: 999px; text-decoration: none; font-size: 14px; font-weight: 700; }
.pill:hover { background: rgba(250, 204, 21, .14); }
.pill--outline { background: transparent; border-color: var(--accent-line); padding: 12px 22px; }
.dotlinks { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 6px 14px; font-size: 14px; }
.dotlinks a { color: var(--accent-text); font-weight: 700; text-decoration: none; }
.dotlinks a:hover { text-decoration: underline; }
.dotlinks span { color: var(--muted-2); }
.box .pills { margin-top: 4px; }

/* ---------- Gallery ---------- */
.gallery { gap: 14px; margin-top: 6px; }
.shot { margin: 0; background: var(--navy-2); border: 1px solid var(--line); border-radius: 14px; padding: 12px; text-align: start; display: flex; flex-direction: column; }
.shot__img { display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 3 / 2; background: var(--navy-3); padding: 0; }
.shot__img img { width: 100%; height: 100%; object-fit: cover; border-radius: 4px; transition: transform .3s; }
.shot__img:hover img { transform: scale(1.03); }
.shot figcaption { padding: 18px 2px 4px; }
.shot h3 { font-size: 14px; font-weight: 700; color: var(--h2); line-height: 1.6; }
.shot p { font-size: 13px; line-height: 1.75; color: var(--ink-soft); margin-top: 6px; }
.shot .more { display: inline-block; margin-top: 10px; color: var(--accent-text); font-weight: 700; font-size: 13px; text-decoration: none; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: 10px; margin: 6px auto 0; max-width: 1136px; text-align: start; }
.faq details { background: var(--navy-2); border: 1px solid var(--line); border-radius: 14px; }
.faq summary { cursor: pointer; padding: 15px 18px; color: var(--accent-text); font-weight: 700; font-size: 14px; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before { content: "◀"; font-size: 11px; margin-inline-end: 8px; display: inline-block; transition: transform .2s; }
[dir="ltr"] .faq summary::before { content: "▶"; }
.faq details[open] summary::before { transform: rotate(-90deg); }
[dir="ltr"] .faq details[open] summary::before { transform: rotate(90deg); }
.faq details p { padding: 0 18px 16px; color: var(--ink-soft); font-size: 14px; }
.faq__more { background: var(--navy-2); border: 1px solid var(--line); border-radius: 14px; padding: 16px 18px; font-size: 14px; color: var(--ink-soft); }
.faq__more a { color: var(--accent-text); font-weight: 700; text-decoration: none; }

/* ---------- Reviews ---------- */
.reviews { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 6px auto 0; max-width: 1136px; }
.review { flex: 1 1 calc(50% - 10px); max-width: calc(50% - 5px); margin: 0; background: var(--navy-2); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; text-align: start; }
.stars { color: var(--accent-text); font-size: 18px; letter-spacing: 2px; }
.review p { font-size: 13px; line-height: 2; color: var(--ink-soft); margin: 6px 0; }
.review cite { font-style: normal; font-size: 12px; color: var(--muted-2); }
.reviews + .inner { margin-top: 14px; }

/* ---------- Contact ---------- */
.contact-list p { margin: 0 0 10px; }
.contact-list b { color: var(--box-ink); }
.contact-list a:not(.btn), .contact-mini a { color: var(--accent-text); font-weight: 700; text-decoration: none; }
.contact-mini { margin-top: 14px !important; font-size: 13px !important; line-height: 2 !important; }
.contact-mini b { color: var(--accent-text); }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy); color: var(--ink-soft); text-align: center; padding: 64px 0 32px; }
.footer-lead { font-size: 14px; }
.footer-lead b { color: var(--accent-text); }
.footer-info { margin: 44px 0 0; }
.footer-info dt { color: var(--muted-2); font-size: 13px; margin-top: 12px; }
.footer-info dd { margin: 4px 0 0; font-size: 14px; }
.footer-info a { color: var(--accent-text); font-weight: 700; text-decoration: none; }
.socials { list-style: none; padding: 0; margin: 44px 0 0; display: grid; gap: 4px; font-size: 15px; }
.socials a { text-decoration: none; }
.socials a:hover { color: var(--accent-text); }
.copy { color: var(--muted-2); font-size: 12px; margin-top: 36px; }

/* ---------- Floating buttons ---------- */
.fab { position: fixed; right: 20px; bottom: 22px; z-index: 70; display: flex; align-items: center; gap: 12px; text-decoration: none; flex-direction: row-reverse; }
.fab__btn { width: 56px; height: 56px; border-radius: 50%; background: var(--yellow); color: #0b0b0b; display: grid; place-items: center; box-shadow: 0 6px 18px rgba(0,0,0,.25); }
.fab__tip { background: #4b5563; color: #fff; font-size: 12px; padding: 4px 8px; border-radius: 3px; }
.to-top { position: fixed; left: 20px; bottom: 26px; z-index: 69; width: 40px; height: 40px; border-radius: 4px; border: 0; background: #4b5563; color: #fff; display: grid; place-items: center; cursor: pointer; opacity: .9; }
.to-top[hidden] { display: none; }

/* ---------- Lightbox ---------- */
.lightbox { position: fixed; inset: 0; z-index: 90; background: rgba(2, 6, 23, .92); display: grid; place-items: center; padding: 20px; }
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; max-width: min(1100px, 100%); }
.lightbox img { max-height: 80vh; width: auto; margin-inline: auto; border-radius: 8px; }
.lightbox figcaption { color: #fff; text-align: center; margin-top: 10px; font-weight: 700; }
.lightbox__close { position: absolute; top: 14px; inset-inline-end: 18px; background: var(--yellow); border: 0; width: 42px; height: 42px; border-radius: 50%; font-size: 26px; cursor: pointer; line-height: 1; }

/* ---------- Articles (blog) ---------- */
.page-article, .page-articles { background: #eef2f6; }
.article-wrap { padding: 64px 20px; }
.article { background: #fff; max-width: 710px; margin: 0 auto; padding: 40px; color: #374151; }
.article__cat { font-size: 13px; margin-bottom: 8px; }
.article__cat a { color: #2563eb; text-decoration: none; }
.article h1 { font-size: 32px; line-height: 1.4; font-weight: 700; color: var(--ink); margin-bottom: 24px; }
.article__img { width: 100%; border-radius: 12px; box-shadow: 0 10px 24px rgba(0,0,0,.12); margin-bottom: 18px; aspect-ratio: 3 / 2; object-fit: cover; }
.article p { font-size: 15px; line-height: 1.85; margin-bottom: 14px; }
.article h2 { font-size: 24px; line-height: 1.45; font-weight: 700; color: var(--ink); margin: 34px 0 14px; }
.article h3 { font-size: 19px; font-weight: 700; color: var(--ink); margin: 18px 0 8px; }
.article ul, .article ol { padding-inline-start: 22px; margin: 0 0 14px; font-size: 15px; line-height: 1.85; }
.article li b.lead-in { color: var(--ink); }
.article__cta { background: #0b1120; border-radius: 16px; box-shadow: 0 12px 28px rgba(2,6,23,.25); padding: 26px 22px; text-align: center; margin: 26px 0 10px; }
.article__cta p { color: #e5e7eb; margin: 0; }
.article__cta .article__cta-title { color: var(--yellow); font-size: 19px; font-weight: 800; margin-bottom: 12px; }
.article__cta .btn--outline { color: var(--yellow); border-color: rgba(250,204,21,.6); }
.article__link { margin-top: 26px; }
.article__link a { color: #2563eb; font-weight: 700; text-decoration: none; }
.article-wrap--wide { max-width: 1240px; margin: 0 auto; }
.articles-head { background: #fff; padding: 40px 50px; margin-bottom: 32px; }
.articles-head h1 { font-size: 34px; color: var(--ink); margin-bottom: 16px; }
.articles-head p { color: #374151; font-size: 15px; }
.articles-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.article-card { background: #fff; padding: 32px 24px; text-decoration: none; color: #374151; box-shadow: 0 2px 10px rgba(0,0,0,.04); display: block; }
.article-card:hover { box-shadow: 0 8px 22px rgba(0,0,0,.08); }
.article-card__cat { color: #2563eb; font-size: 13px; }
.article-card h2 { font-size: 20px; line-height: 1.45; color: var(--ink); margin: 14px 0 16px; }
.article-card p { font-size: 15px; line-height: 1.8; }

/* ---------- Light mode (dark sections become light) ---------- */
[data-theme="light"] {
  --navy: #f5f4ef; --navy-2: #ffffff; --navy-3: #f1f0ea; --line: #e5e1d6;
  --box-ink: #111827; --h2: #111827; --ink-soft: #374151; --muted-2: #6b7280;
  --accent-text: #a16207; --accent-line: #d4a72c; --pill-bg: rgba(202, 138, 4, .08);
}
[data-theme="light"] .box, [data-theme="light"] .strip { border: 1px solid var(--line); }
[data-theme="light"] .badge { border-color: #d4a72c; }
[data-theme="light"] .pill { border-color: #e3c56b; }
[data-theme="light"] .cards-cream .card { border: 1px solid #f1e7b8; }
[data-theme="light"] .site-footer { border-top: 1px solid var(--line); }

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .menu-btn { display: block; }
  .site-header__inner { flex-wrap: wrap; gap: 12px; }
  .brand { flex: 1; }
  .site-nav { display: none; width: 100%; margin: 0 0 12px; }
  .site-nav.is-open { display: block; }
  .site-nav > ul { flex-direction: column; align-items: stretch; }
  .site-nav a { line-height: 1.4; padding: 12px 6px; border-bottom: 1px solid #f1f5f9; }
  .has-sub { flex-wrap: wrap; }
  .has-sub > a { flex: 1; }
  .sub-btn { padding: 10px 14px; }
  .sub { position: static; opacity: 1; visibility: visible; box-shadow: none; border: 0; padding: 0 16px 0 0; width: 100%; display: none; }
  [dir="ltr"] .sub { padding: 0 0 0 16px; }
  .has-sub.is-open .sub { display: block; }
  .site-nav .lang a { margin: 10px 0 0; text-align: center; padding: 12px; }
  .theme-btn { width: 100%; height: 42px; margin: 10px 0 0; }
  .menu-btn[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-btn[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .menu-btn[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }
  .grid--4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 860px) {
  .grid--3, .articles-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px) {
  .brand { font-size: 22px; }
  .phone-pill { width: 70px; height: 42px; }
  .box { border-radius: 16px; padding: 22px 16px; }
  .box h1 { font-size: 20px; line-height: 1.5; }
  .grid--2, .grid--3, .grid--4, .articles-grid { grid-template-columns: 1fr; }
  .grid--2 > :last-child:nth-child(odd) { width: 100%; }
  .review { flex-basis: 100%; max-width: 100%; }
  .btns--inline .btn { flex: 1 1 100%; }
  .fab__tip { display: none; }
  .article { padding: 24px 18px; }
  .article h1 { font-size: 26px; }
  .articles-head { padding: 28px 20px; }
  .article-wrap { padding: 28px 12px; }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; scroll-behavior: auto !important; } }
