/* All About Curtains */
:root {
  --bg: #FFFFFF;
  --paper: #F7F7F5;
  --ink: #1F2A2E;
  --text: #33332F;
  --muted: #4A4A44;
  --soft: #6B6458;
  --line: #E5E5E2;
  --line-strong: #D6D6D2;
  --accent: #2F5D50;
  --accent-dark: #1E3F36;
  --sage: #E4EAE3;
  --sand: #F2F2F0;
  --serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --sans: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --radius: 6px;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.5; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); text-decoration: underline; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

.container { max-width: 1240px; margin: 0 auto; padding: 0 24px; }
.narrow { max-width: 800px; }
.visually-hidden { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 4px; z-index: 10; }
.skip-link:focus { top: 12px; color: #fff; }

/* ---------- Header */
.site-header { border-bottom: 1px solid var(--line); background: var(--bg); }
.site-header__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 28px; padding-top: 20px; padding-bottom: 20px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); }
.brand:hover { text-decoration: none; color: var(--ink); }
.brand__mark { color: var(--accent); flex: none; }
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-family: var(--serif); font-size: 30px; font-weight: 600; }
.brand__tagline { font-size: 11px; letter-spacing: .22em; text-transform: uppercase; color: var(--soft); margin-top: 6px; }

.site-nav { display: flex; flex-wrap: wrap; gap: 8px 26px; font-size: 15px; font-weight: 500; }
.site-nav a { color: var(--ink); padding: 6px 0; border-bottom: 2px solid transparent; }
.site-nav a:hover { text-decoration: none; border-bottom-color: var(--line-strong); }
.site-nav a[aria-current="page"] { border-bottom-color: var(--accent); }

.search-form { display: flex; align-items: center; border: 1px solid var(--line-strong); border-radius: 24px; background: var(--paper); padding-left: 16px; }
.search-form input { border: 0; background: transparent; font: inherit; font-size: 14px; width: 150px; height: 42px; color: var(--ink); }
.search-form input:focus { outline: none; }
.search-form:focus-within { outline: 3px solid var(--accent); outline-offset: 2px; }
.search-form button { width: 44px; height: 42px; border: 0; background: transparent; color: var(--ink); cursor: pointer; display: flex; align-items: center; justify-content: center; }

.menu-toggle { display: none; width: 44px; height: 44px; border: 1px solid var(--line-strong); border-radius: 22px; background: transparent; color: var(--ink); cursor: pointer; align-items: center; justify-content: center; }

@media (max-width: 960px) {
  .menu-toggle { display: flex; }
  .site-nav { display: none; order: 3; width: 100%; flex-direction: column; gap: 0; border-top: 1px solid var(--line); padding-top: 8px; }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .site-header__actions { order: 4; width: 100%; }
  .search-form input { width: 100%; }
  .search-form { width: 100%; }
}

/* ---------- Ads */
.ad { margin: 24px auto; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ad--top { max-width: 728px; margin-top: 20px; margin-bottom: 8px; }
.ad__label { font-size: 11px; letter-spacing: .12em; text-transform: uppercase; color: var(--soft); text-align: center; }
.ad__box { border: 1px dashed #C4C4BF; border-radius: 4px; background: var(--sand); color: var(--soft); font-size: 13px; display: flex; align-items: center; justify-content: center; text-align: center; padding: 8px; }
.ad--leaderboard .ad__box { height: 90px; }
.ad--in-feed .ad__box { height: 120px; }
.ad--in-article { margin: 32px 0; }
.ad--in-article .ad__box { height: 250px; }
.ad--sidebar .ad__box { height: 250px; }
.ad--sidebar-tall .ad__box { height: 600px; }

/* ---------- Shared bits */
.eyebrow { margin: 0 0 14px; font-size: 13px; letter-spacing: .2em; text-transform: uppercase; color: var(--accent); font-weight: 600; display: block; }
.eyebrow--light { color: #C9B79C; }
.btn { display: inline-block; padding: 15px 28px; border-radius: 28px; font-weight: 600; font-size: 15px; border: 0; cursor: pointer; font-family: inherit; }
.btn:hover { text-decoration: none; }
.btn--dark { background: var(--ink); color: var(--bg); }
.btn--dark:hover { background: #2C3A3F; color: var(--bg); }
.btn--light { background: var(--bg); color: var(--ink); }
.btn--light:hover { background: #fff; color: var(--ink); }
.link-underline { display: inline-block; font-weight: 600; color: var(--ink); border-bottom: 2px solid var(--accent); padding: 4px 0; }
.link-underline:hover { text-decoration: none; color: var(--accent-dark); }
.empty { font-size: 17px; color: var(--muted); }

/* ---------- Hero */
.hero { display: flex; flex-wrap: wrap; gap: 48px; align-items: center; padding-top: 48px; padding-bottom: 40px; }
.hero__text { flex: 1 1 440px; min-width: 0; }
.hero__media { flex: 1 1 440px; min-width: 0; }
.hero__media img { width: 100%; max-height: 560px; object-fit: cover; border-radius: var(--radius); }
.hero__title { margin: 0 0 22px; font-family: var(--serif); font-size: clamp(40px, 6vw, 68px); line-height: 1.02; font-weight: 600; }
.hero__lead { margin: 0 0 32px; font-size: 18px; line-height: 1.65; color: var(--muted); max-width: 540px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: center; }
.hero__meta { margin: 28px 0 0; font-size: 13px; color: var(--soft); }

/* ---------- Topic chips */
.chips { display: flex; flex-wrap: wrap; gap: 12px; padding-top: 8px; padding-bottom: 40px; }
.chip { padding: 11px 20px; border: 1px solid var(--line-strong); border-radius: 24px; font-size: 14px; font-weight: 500; color: var(--ink); background: var(--paper); }
.chip:hover { text-decoration: none; border-color: var(--accent); color: var(--accent); }

/* ---------- Sections */
.section { padding-top: 40px; padding-bottom: 56px; }
.section--tight { padding-top: 8px; }
.section__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 12px; margin-bottom: 28px; border-top: 1px solid var(--line); padding-top: 40px; }
.section__title { margin: 0; font-family: var(--serif); font-size: clamp(32px, 4vw, 46px); font-weight: 600; line-height: 1.1; }
.section__center { text-align: center; max-width: 640px; margin: 0 auto 40px; }
.section__center .section__title { margin-bottom: 14px; }
.section__lead { margin: 0; font-size: 17px; line-height: 1.6; color: var(--muted); }

/* ---------- Cards */
.card-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); gap: 36px 32px; }
.card-grid--small { grid-template-columns: repeat(auto-fill, minmax(min(220px, 100%), 1fr)); gap: 24px; }
.card__link { display: flex; flex-direction: column; gap: 12px; color: var(--ink); }
.card__link:hover { text-decoration: none; color: var(--ink); }
.card__link:hover .card__title { color: var(--accent); }
.card__img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius); background: var(--sand); }
.card .eyebrow { margin: 4px 0 0; font-size: 12px; }
.card__title { margin: 0; font-family: var(--serif); font-size: 28px; line-height: 1.15; font-weight: 600; }
.card-grid--small .card__title { font-size: 22px; }
.card-grid--small .card__excerpt, .card-grid--small .card__meta { display: none; }
.card__excerpt { margin: 0; font-size: 15px; line-height: 1.6; color: var(--muted); }
.card__meta { font-size: 13px; color: var(--soft); }

/* ---------- Fabric band */
.band { background: var(--ink); color: #EDE6DA; margin-top: 16px; }
.band__inner { display: flex; flex-wrap: wrap; gap: 48px; padding-top: 80px; padding-bottom: 80px; }
.band__intro { flex: 1 1 320px; min-width: 0; }
.band__intro p { font-size: 17px; line-height: 1.65; color: #C8C1B4; margin: 0 0 28px; }
.band__title { margin: 0 0 20px; font-family: var(--serif); font-size: clamp(36px, 5vw, 52px); line-height: 1.05; font-weight: 600; color: var(--paper); }
.swatches { flex: 2 1 520px; min-width: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 16px; }
.swatch { display: flex; flex-direction: column; gap: 10px; padding: 14px; border: 1px solid #3A474B; border-radius: var(--radius); }
.swatch__sample { height: 72px; border-radius: 4px; }
.swatch__name { font-weight: 600; color: var(--paper); }
.swatch__note { font-size: 13px; color: #B8B1A4; line-height: 1.5; }

/* ---------- Steps */
.steps-section { padding-top: 80px; }
.steps { list-style: none; margin: 0 0 36px; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 24px; }
.step { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.step__n { font-family: var(--serif); font-size: 48px; font-weight: 600; color: var(--accent); line-height: 1; }
.step h3 { margin: 16px 0 10px; font-size: 18px; }
.step p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--muted); }

/* ---------- Page heads */
.page-head { padding-top: 40px; padding-bottom: 32px; }
.page-head--center { text-align: center; max-width: 640px; margin: 0 auto; padding-bottom: 80px; }
.page-head--center .search-big { margin: 0 auto 28px; }
.page-head__title { margin: 0 0 12px; font-family: var(--serif); font-size: clamp(40px, 5vw, 58px); line-height: 1.05; font-weight: 600; }
.page-head__lead { margin: 0 0 24px; font-size: 18px; line-height: 1.6; color: var(--muted); max-width: 640px; }
.breadcrumb { font-size: 13px; color: var(--soft); margin-bottom: 20px; }
.breadcrumb span { color: var(--soft); }
.search-big { display: flex; flex-wrap: wrap; gap: 12px; max-width: 560px; }
.search-big input { flex: 1 1 240px; min-width: 0; height: 52px; padding: 0 20px; border: 1px solid var(--line-strong); border-radius: 26px; font: inherit; background: #fff; color: var(--ink); }
.result-count { color: var(--muted); margin: 0 0 24px; }
.pagination { display: flex; gap: 24px; justify-content: center; align-items: center; margin-top: 48px; font-weight: 600; }
.pagination span { color: var(--soft); font-weight: 500; }

/* ---------- Article layout */
.layout { display: flex; flex-wrap: wrap; gap: 56px; align-items: flex-start; padding-top: 32px; padding-bottom: 72px; }
.article { flex: 999 1 620px; min-width: 0; max-width: 780px; }
.article__title { margin: 0 0 18px; font-family: var(--serif); font-size: clamp(38px, 5vw, 58px); line-height: 1.04; font-weight: 600; }
.article__meta { margin: 0 0 28px; font-size: 14px; color: var(--soft); }
.article__figure { margin: 0 0 32px; }
.article__figure img { width: 100%; max-height: 440px; object-fit: cover; border-radius: var(--radius); }
.article__figure figcaption { margin-top: 10px; font-size: 13px; color: var(--soft); }

.prose { font-size: 18px; line-height: 1.75; color: var(--text); }
.prose > * { margin-top: 0; }
.prose p, .prose ul, .prose ol { margin: 0 0 22px; }
.prose ul, .prose ol { padding-left: 24px; }
.prose li { margin-bottom: 8px; }
.prose h2 { margin: 48px 0 16px; font-family: var(--serif); font-size: clamp(30px, 3.5vw, 38px); line-height: 1.15; font-weight: 600; color: var(--ink); }
.prose h3 { margin: 32px 0 10px; font-size: 20px; line-height: 1.3; color: var(--ink); }
.prose a { text-decoration: underline; text-underline-offset: 3px; }
.prose strong { color: var(--ink); }
.prose blockquote { margin: 0 0 22px; padding: 18px 24px; background: var(--sage); border-radius: var(--radius); }
.prose img { border-radius: var(--radius); margin: 8px 0 24px; }
.prose figure { margin: 8px 0 32px; }
.prose figure img { width: 100%; height: auto; margin: 0; border: 1px solid var(--line); background: #fff; }
.prose figcaption { margin-top: 10px; font-size: 14px; line-height: 1.5; color: var(--soft); }
.prose h4 { margin: 24px 0 8px; font-size: 17px; color: var(--ink); }
.prose table { width: 100%; border-collapse: collapse; font-size: 15px; line-height: 1.5; margin: 0 0 28px; background: var(--paper); }
@media (max-width: 700px) { .prose table { display: block; overflow-x: auto; } }
.prose thead { background: var(--sand); }
.prose th, .prose td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--line); vertical-align: top; }
.prose th { font-weight: 600; color: var(--ink); white-space: nowrap; }

.related { border-top: 1px solid var(--line); margin-top: 48px; padding-top: 32px; }
.related__title { margin: 0 0 22px; font-family: var(--serif); font-size: 32px; font-weight: 600; }

/* ---------- Sidebar */
.sidebar { flex: 1 1 300px; min-width: 0; max-width: 340px; display: flex; flex-direction: column; gap: 32px; }
.sidebar .ad { margin: 0; }
.sidebar__title { margin: 0 0 16px; font-family: var(--serif); font-size: 28px; font-weight: 600; }
.popular { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 14px; }
.popular li { display: flex; gap: 14px; align-items: baseline; border-bottom: 1px solid var(--line); padding-bottom: 14px; }
.popular__n { font-family: var(--serif); font-size: 26px; font-weight: 600; color: var(--accent); min-width: 18px; }
.popular a { font-size: 15px; font-weight: 500; line-height: 1.45; color: var(--ink); }
.sidebar__topics ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.sidebar__topics a { display: inline-block; padding: 8px 16px; border: 1px solid var(--line-strong); border-radius: 20px; font-size: 14px; color: var(--ink); background: var(--paper); }
.sidebar__topics a:hover { text-decoration: none; border-color: var(--accent); color: var(--accent); }
@media (max-width: 1000px) { .sidebar { max-width: none; } }

/* ---------- Footer */
.site-footer { border-top: 1px solid var(--line); margin-top: 24px; }
.site-footer__inner { display: flex; flex-wrap: wrap; gap: 40px 64px; justify-content: space-between; padding-top: 56px; padding-bottom: 32px; }
.site-footer__about { flex: 1 1 260px; }
.site-footer__about p { margin: 0; font-size: 14px; line-height: 1.6; color: var(--muted); max-width: 300px; }
.site-footer__name { font-family: var(--serif); font-size: 28px; font-weight: 600; margin-bottom: 12px; }
.site-footer__cols { display: flex; flex-wrap: wrap; gap: 40px 64px; }
.site-footer__col { display: flex; flex-direction: column; gap: 10px; font-size: 14px; }
.site-footer__col a { color: var(--muted); }
.site-footer__heading { font-weight: 600; margin-bottom: 4px; }
.site-footer__bottom { padding-top: 20px; padding-bottom: 36px; border-top: 1px solid var(--line); font-size: 13px; color: var(--soft); }
