/* Coatfire — "Hearth Alive" */
:root {
  --bg: #140E0A;
  --bg-raised: #1A130E;
  --bg-deep: #0E0907;
  --line: #33281F;
  --ink: #F5EDE6;
  --ink-soft: #D6C8BC;
  --ink-body: #CDBFB3;
  --muted: #B3A497;
  --faint: #8F8073;
  --accent: #D89574;
  --hearth: #E3875D;
  --serif: 'Newsreader', Georgia, 'Times New Roman', serif;
  --sans: 'Hanken Grotesk', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --wrap: 1240px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; -webkit-text-size-adjust: 100%; }
body { margin: 0; min-width: 320px; background: var(--bg); color: var(--ink); font-family: var(--sans); font-size: 17px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--ink); }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 2px; }
h1, h2, h3, p, ul { margin: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.skip-link { position: absolute; top: -100px; left: 16px; z-index: 100; padding: 12px 18px; background: var(--ink); color: var(--bg); font-weight: 600; text-decoration: none; }
.skip-link:focus { top: 12px; }
.serif { font-family: var(--serif); font-weight: 400; }
.kicker { font-size: 15px; color: var(--muted); }

/* Header */
.site-header { position: relative; z-index: 2; }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px 32px; padding-top: 16px; padding-bottom: 16px; }
.brand { display: flex; align-items: center; gap: 12px; min-height: 44px; text-decoration: none; }
.brand img { height: 44px; width: auto; }
.brand span { font-family: var(--serif); font-size: 24px; font-weight: 500; letter-spacing: -0.01em; color: var(--ink); }
.site-nav { display: flex; flex-wrap: wrap; gap: 0 28px; font-size: 15px; }
.site-nav a { display: inline-flex; align-items: center; min-height: 44px; color: #C9BBAF; text-decoration: none; }
.site-nav a:hover { color: var(--ink); }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 10px; min-height: 52px; padding: 0 26px; border-radius: 999px; font-weight: 600; font-size: 16px; text-decoration: none; transition: filter .15s, background-color .3s, color .3s; }
.btn:hover { filter: brightness(1.08); }
.btn-accent { background: var(--accent); color: var(--bg); }
.btn-accent:hover { color: var(--bg); }
.text-link { display: inline-flex; align-items: center; min-height: 52px; text-underline-offset: 6px; text-decoration-color: #6B5747; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }

/* Hero */
.hero { position: relative; overflow: hidden; display: flex; flex-direction: column; min-height: min(680px, calc(100svh - 76px)); }
.hero-body { position: relative; z-index: 1; flex-grow: 1; display: flex; flex-direction: column; justify-content: center; padding-top: 64px; padding-bottom: 120px; }
.hero h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(52px, 8vw, 120px); line-height: 0.98; letter-spacing: -0.03em; max-width: 12ch; margin: 28px 0; }
.hero h1 em { color: var(--accent); white-space: nowrap; }
.hero .lede { font-size: 20px; line-height: 1.55; color: var(--ink-soft); max-width: 36ch; margin-bottom: 36px; }
.hearth { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: var(--hearth); opacity: .6; animation: cf-flicker 4.2s ease-in-out infinite; }
.embers { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.ember { position: absolute; bottom: -12px; border-radius: 50%; opacity: 0; animation-name: cf-rise-l; animation-timing-function: cubic-bezier(.3,.1,.5,1); animation-iteration-count: infinite; will-change: transform, opacity; }
.ember.r { animation-name: cf-rise-r; }
.hero.is-paused .ember, .hero.is-paused .hearth { animation-play-state: paused; }
@keyframes cf-rise-l { 0% { transform: translate3d(0,0,0); opacity: 0; } 12% { opacity: .95; } 70% { opacity: .6; } 100% { transform: translate3d(-70px,-560px,0); opacity: 0; } }
@keyframes cf-rise-r { 0% { transform: translate3d(0,0,0); opacity: 0; } 12% { opacity: .95; } 70% { opacity: .6; } 100% { transform: translate3d(70px,-560px,0); opacity: 0; } }
@keyframes cf-flicker { 0%, 100% { opacity: .55; } 45% { opacity: .8; } 70% { opacity: .6; } }

/* Section headings */
.section-title { font-family: var(--serif); font-weight: 400; font-size: clamp(40px, 5vw, 64px); line-height: 1.05; letter-spacing: -0.02em; }
.label { display: block; font-size: 15px; color: var(--muted); margin-bottom: 8px; }

/* Products + switcher */
.theme-lovou { --p-bg: #2B1B16; --p-ink: #F5EDE6; --p-body: #D9C9BD; --p-muted: #B59E90; --p-line: #4A342B; --p-panel: #21140F; --p-accent: #E8956A; --p-cta-bg: #E8956A; --p-cta-ink: #2B1B16; }
.theme-tb { --p-bg: #F6E5CC; --p-ink: #2B211A; --p-body: #4D3F33; --p-muted: #6B5A49; --p-line: #D9C3A3; --p-panel: #F6E4CC; --p-accent: #1B6F68; --p-cta-bg: #2B211A; --p-cta-ink: #F6E5CC; }

.products { background: var(--p-bg); color: var(--p-ink); transition: background-color .6s ease, color .6s ease; }
.products-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px 48px; padding-top: 80px; padding-bottom: 56px; }
.products-head .label { color: var(--p-muted); transition: color .6s; }
.switch { display: none; gap: 6px; padding: 6px; border: 1px solid var(--p-line); border-radius: 999px; transition: border-color .6s; }
.js .switch { display: flex; }
.switch button { min-height: 48px; padding: 0 24px; border: 0; border-radius: 999px; font: inherit; font-weight: 600; font-size: 16px; cursor: pointer; background: transparent; color: var(--p-ink); transition: background-color .3s, color .3s; }
.switch button[aria-selected="true"] { background: var(--p-ink); color: var(--p-bg); }

.panel { background: var(--p-bg); color: var(--p-ink); }
.js .panel { background: transparent; }
.js .panel[hidden] { display: none; }
.js .panel.is-entering .panel-grid { animation: cf-fade .45s ease both; }
@keyframes cf-fade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.panel-grid { display: flex; flex-wrap: wrap; align-items: center; gap: 48px 72px; padding-top: 0; padding-bottom: 96px; }
.no-js-gap { padding-top: 72px; }
.js .no-js-gap { padding-top: 0; }
.panel-art { flex: 1 1 400px; min-height: 440px; display: flex; align-items: center; justify-content: center; padding: 32px; border-radius: 8px; background: var(--p-panel); }
.panel-art img { width: 100%; max-width: 400px; height: auto; }
.theme-lovou .panel-art img { width: 82%; }
.panel-copy { flex: 1.15 1 460px; min-width: 0; }
.panel-meta { display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 15px; margin-bottom: 16px; }
.panel-meta strong { font-weight: 600; color: var(--p-accent); }
.panel-meta span { color: var(--p-muted); }
.panel h3 { font-family: var(--serif); font-weight: 400; font-size: clamp(44px, 5vw, 72px); line-height: 1; letter-spacing: -0.03em; margin-bottom: 8px; }
.panel .tagline { font-family: var(--serif); font-style: italic; font-size: 26px; line-height: 1.3; margin-bottom: 22px; }
.panel .body { color: var(--p-body); max-width: 54ch; margin-bottom: 12px; }
.panel .tags { font-size: 15px; color: var(--p-muted); margin: 12px 0 32px; }
.panel .btn { background: var(--p-cta-bg); color: var(--p-cta-ink); }
.panel .btn:hover { color: var(--p-cta-ink); }
.panel .domain { display: inline-flex; align-items: center; min-height: 48px; color: var(--p-ink); font-size: 15px; text-underline-offset: 5px; }

/* About */
.about { background: var(--bg-raised); border-top: 1px solid var(--line); }
.about .wrap { display: flex; flex-wrap: wrap; gap: 24px 64px; padding-top: 96px; padding-bottom: 96px; }
.about-head { flex: 1 1 300px; }
.about-body { flex: 1.6 1 480px; min-width: 0; }
.about-lead { font-family: var(--serif); font-size: clamp(22px, 2.2vw, 28px); line-height: 1.4; margin-bottom: 20px; }
.about-body p + p { font-size: 18px; color: var(--ink-body); max-width: 60ch; }

/* Legal + contact */
.info { border-top: 1px solid var(--line); }
.info .wrap { display: flex; flex-wrap: wrap; gap: 56px 72px; padding-top: 88px; padding-bottom: 88px; }
.info-col { flex: 1 1 440px; min-width: 0; }
.info-col h2 { font-family: var(--serif); font-weight: 400; font-size: 40px; letter-spacing: -0.02em; margin-bottom: 12px; }
.info-col > p { color: var(--muted); font-size: 16px; max-width: 50ch; margin-bottom: 24px; }
.rows { border-bottom: 1px solid var(--line); }
.row-link { display: block; padding: 14px 0; border-top: 1px solid var(--line); text-decoration: none; }
.row-link .t { display: block; font-family: var(--serif); font-size: 21px; }
.row-link .d { display: block; font-size: 15px; color: var(--muted); }
.row-link:hover .t { color: var(--accent); }
.row-kv { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 16px; padding: 16px 0; border-top: 1px solid var(--line); }
.row-kv .k { color: var(--muted); font-size: 15px; }
.row-kv a { text-underline-offset: 4px; text-decoration-color: #6B5747; }
.row-kv address { font-style: normal; text-align: right; font-size: 15px; }

/* Footer */
.site-footer { background: var(--bg-deep); border-top: 1px solid var(--line); }
.site-footer .wrap { padding-top: 56px; padding-bottom: 36px; }
.footer-cols { display: flex; flex-wrap: wrap; gap: 40px 64px; margin-bottom: 48px; }
.footer-brand { flex: 2 1 280px; }
.footer-brand p:first-child { font-family: var(--serif); font-size: 28px; font-weight: 500; margin-bottom: 10px; }
.footer-brand p + p { color: var(--muted); font-size: 15px; max-width: 32ch; }
.footer-col { flex: 1 1 180px; display: flex; flex-direction: column; }
.footer-col h2 { font-size: 13px; font-weight: 500; color: var(--faint); text-transform: uppercase; letter-spacing: .08em; margin-bottom: 8px; }
.footer-col a { display: flex; align-items: center; min-height: 40px; font-size: 15px; color: var(--ink-soft); text-decoration: none; }
.footer-col a:hover { color: var(--ink); }
.footer-base { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 32px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 13px; color: var(--faint); }

/* Inner pages */
.page-head { padding-top: 56px; padding-bottom: 48px; border-bottom: 1px solid var(--line); }
.back { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 15px; color: var(--muted); text-decoration: none; margin-bottom: 24px; }
.back:hover { color: var(--ink); }
.page-head h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(44px, 6.4vw, 88px); line-height: 1; letter-spacing: -0.03em; margin: 12px 0 20px; }
.page-head .lede { font-size: 20px; color: var(--ink-soft); max-width: 48ch; }
.page-body { padding-top: 56px; padding-bottom: 104px; }
.notice { display: flex; flex-wrap: wrap; gap: 12px 64px; padding: 36px 0; border-top: 1px solid var(--line); }
.notice:first-child { border-top: 0; padding-top: 0; }
.notice h2 { flex: 1 1 260px; font-family: var(--serif); font-weight: 400; font-size: 30px; line-height: 1.15; letter-spacing: -0.015em; }
.notice-body { flex: 2.2 1 440px; min-width: 0; max-width: 68ch; }
.notice-body p, .notice-body ul { color: var(--ink-body); margin-bottom: 14px; }
.notice-body ul { padding-left: 1.2em; }
.notice-body li { margin-bottom: 6px; }
.notice-body li::marker { color: var(--accent); }
.notice-body p a { color: var(--accent); text-underline-offset: 4px; }
.notice-links { display: flex; flex-direction: column; align-items: flex-start; margin-top: 4px; }
.notice-links a { display: inline-flex; align-items: center; min-height: 44px; color: var(--accent); text-underline-offset: 5px; }
.notice-links a:hover { color: var(--ink); }

.notfound { min-height: 60vh; display: flex; flex-direction: column; justify-content: center; padding-top: 72px; padding-bottom: 120px; }
.notfound h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(52px, 8vw, 112px); line-height: 1; letter-spacing: -0.03em; margin: 16px 0 20px; }
.notfound p.lede { font-size: 20px; color: var(--ink-soft); max-width: 40ch; margin-bottom: 32px; }

@media (max-width: 600px) {
  .hero-body { padding-top: 40px; padding-bottom: 88px; }
  .products-head { padding-top: 64px; padding-bottom: 40px; }
  .panel-art { min-height: 300px; }
  .row-kv address { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .ember { display: none; }
  .hearth, .js .panel.is-entering .panel-grid { animation: none; }
  .products, .switch button, .btn { transition: none; }
}
