/*
Theme Name: There and Draft Again
Theme URI: https://thehobbit.kaina.dev/
Author: Kaina & Codex
Description: A warm, storybook WordPress theme for a private Hobbit-inspired draft gathering.
Version: 1.9.2
Requires at least: 6.4
Requires PHP: 8.0
Text Domain: tada
*/

:root {
  --ink: #1f241d;
  --forest: #243b2b;
  --forest-dark: #14251b;
  --moss: #667650;
  --cream: #f4ecd8;
  --parchment: #e9d7ad;
  --gold: #d5a33b;
  --copper: #a75d36;
  --brown: #5f3a26;
  --white: #fffdf7;
  --shadow: 0 20px 60px rgba(20, 37, 27, .22);
  --radius: 28px;
  --serif: Georgia, "Times New Roman", serif;
  --sans: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--cream); font: 17px/1.65 var(--sans); }
img { max-width: 100%; height: auto; }
a { color: var(--copper); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; }
.screen-reader-text { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.wrap { width: min(1180px, calc(100% - 40px)); margin-inline: auto; }

.site-header { position: sticky; top: 0; z-index: 20; color: var(--white); background: rgba(20,37,27,.96); border-bottom: 1px solid rgba(255,255,255,.12); backdrop-filter: blur(12px); }
.header-inner { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 22px; }
.site-brand { max-width: 290px; display: grid; gap: 3px; color: var(--white); text-decoration: none; }
.site-brand-title { font: 700 clamp(1.05rem, 1.6vw, 1.4rem)/1.1 var(--serif); }
.site-tagline { color: rgba(255,255,255,.72); font: 500 .7rem/1.2 var(--sans); letter-spacing: .025em; }
.tada-site-nav ul { display: flex; align-items: center; gap: 16px; list-style: none; margin: 0; padding: 0; }
.tada-site-nav a { color: var(--white); text-decoration: none; font-size: .9rem; font-weight: 700; }
.tada-site-nav a:hover { color: var(--gold); }
.tada-menu-toggle { display: none; width: 46px; height: 42px; padding: 0; align-items: center; justify-content: center; color: var(--white); background: transparent; border: 1px solid rgba(255,255,255,.35); border-radius: 10px; cursor: pointer; }
.tada-menu-toggle-icon, .tada-menu-toggle-icon::before, .tada-menu-toggle-icon::after { display: block; width: 22px; height: 2px; background: currentColor; transition: transform .2s ease, opacity .2s ease; }
.tada-menu-toggle-icon { position: relative; }
.tada-menu-toggle-icon::before, .tada-menu-toggle-icon::after { content: ""; position: absolute; left: 0; }
.tada-menu-toggle-icon::before { top: -7px; }
.tada-menu-toggle-icon::after { top: 7px; }
.tada-menu-toggle[aria-expanded="true"] .tada-menu-toggle-icon { background: transparent; }
.tada-menu-toggle[aria-expanded="true"] .tada-menu-toggle-icon::before { top: 0; transform: rotate(45deg); }
.tada-menu-toggle[aria-expanded="true"] .tada-menu-toggle-icon::after { top: 0; transform: rotate(-45deg); }
.nav-cta a, .button { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 10px 22px; border: 1px solid var(--gold); border-radius: 999px; color: var(--forest-dark); background: var(--gold); text-decoration: none; font-weight: 800; cursor: pointer; }
.nav-cta a:hover, .button:hover { color: var(--white); background: var(--copper); border-color: var(--copper); }
.tada-site-nav .mobile-nav-cta { display: none; }

.hero { position: relative; overflow: hidden; min-height: clamp(660px, calc(100svh - 76px), 840px); display: grid; align-items: end; color: var(--white); background: var(--forest-dark); }
.hero::after { content: ""; position: absolute; inset: 0; z-index: 1; pointer-events: none; background: linear-gradient(90deg, rgba(13,28,19,.1), rgba(13,28,19,.58)); }
.hero-media { position: absolute; inset: 0; z-index: 0; overflow: hidden; margin: 0; }
.hero-media img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: var(--tada-focus-x) var(--tada-focus-y); transform: scale(var(--tada-zoom)); transform-origin: var(--tada-focus-x) var(--tada-focus-y); }
.hero .wrap { position: relative; z-index: 2; min-height: inherit; display: flex; justify-content: flex-start; align-items: flex-end; }
.hero-card { width: min(440px, 100%); margin: 0 0 34px; padding: clamp(20px, 3vw, 28px); background: rgba(20,37,27,.58); border: 1px solid rgba(255,255,255,.2); border-radius: 18px; box-shadow: 0 14px 42px rgba(20,37,27,.2); backdrop-filter: blur(5px); }
.hero h1 { font-size: clamp(2.35rem, 4vw, 3.55rem); }
.hero .eyebrow { font-size: .72rem; letter-spacing: .13em; }
.eyebrow { margin: 0 0 10px; color: var(--gold); text-transform: uppercase; letter-spacing: .16em; font-size: .82rem; font-weight: 900; }
h1,h2,h3 { font-family: var(--serif); line-height: 1.08; }
h1 { margin: 0 0 18px; font-size: clamp(2.8rem, 5vw, 4.7rem); }
h2 { margin: 0 0 18px; font-size: clamp(2rem, 3.5vw, 3.2rem); }
h3 { font-size: clamp(1.25rem, 1.8vw, 1.65rem); }
.hero-copy { max-width: 52ch; font-size: 1.02rem; }
.hero-tagline { margin: -8px 0 14px; color: var(--gold); font: italic 700 1rem/1.35 var(--serif); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.hero-actions .button { min-height: 42px; padding: 8px 16px; font-size: .86rem; }
.button.secondary { color: var(--white); background: transparent; border-color: rgba(255,255,255,.45); }

.section { padding: clamp(70px, 9vw, 120px) 0; }
.section.dark { color: var(--white); background: var(--forest-dark); }
.section.gold { background: var(--gold); }
.section-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: clamp(36px, 7vw, 90px); align-items: center; }
.prose { max-width: 64ch; }
.story-image { overflow: hidden; min-height: 520px; background: var(--moss); border-radius: 52% 52% 10px 10px / 32% 32% 10px 10px; box-shadow: var(--shadow); }
.story-image img { width: 100%; height: 100%; object-fit: cover; min-height: 520px; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0,1fr)); gap: 22px; }
.card { padding: 28px; background: var(--white); border: 1px solid rgba(31,36,29,.1); border-radius: 20px; box-shadow: 0 12px 30px rgba(20,37,27,.09); }
.dark .card { background: #203127; border-color: rgba(255,255,255,.1); }
.schedule { list-style: none; padding: 0; margin: 34px 0 0; border-top: 1px solid rgba(31,36,29,.18); }
.schedule li { display: grid; grid-template-columns: 160px 1fr; gap: 22px; padding: 22px 0; border-bottom: 1px solid rgba(31,36,29,.18); }
.schedule time { font-weight: 900; color: var(--brown); }
.note { margin-top: 26px; padding: 18px 22px; border-left: 5px solid var(--gold); background: rgba(255,255,255,.55); }
.seat-meter { padding: 30px; color: var(--white); background: var(--forest); border-radius: 22px; }
.seat-meter strong { display: block; color: var(--gold); font: 700 2.5rem var(--serif); }

.content-area { padding: 70px 0 100px; }
.entry-header { max-width: 850px; margin-bottom: 40px; }
.entry-title { font-size: clamp(2.5rem, 5vw, 4rem); }
.page-hero-image { overflow: hidden; margin: 0 0 42px; border-radius: 24px; box-shadow: var(--shadow); }
.page-hero-image img { display: block; width: 100%; aspect-ratio: 16/7; object-fit: cover; object-position: var(--tada-focus-x) var(--tada-focus-y); transform: scale(var(--tada-zoom)); transform-origin: var(--tada-focus-x) var(--tada-focus-y); }
.front-page-content { padding: clamp(52px, 7vw, 90px) 0; }
.front-page-content > :first-child { margin-top: 0; }
.front-page-content > :last-child { margin-bottom: 0; }
.post-grid { display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 24px; }
.post-card { overflow: hidden; background: var(--white); border-radius: 18px; box-shadow: var(--shadow); }
.post-card img { width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.post-card-body { padding: 26px; }

.tada-form { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 20px; max-width: 860px; }
.tada-form .full { grid-column: 1 / -1; }
.tada-form label { display: grid; gap: 7px; font-weight: 800; }
.tada-form input, .tada-form select, .tada-form textarea { width: 100%; min-height: 48px; padding: 11px 13px; border: 1px solid #9d987f; border-radius: 10px; background: var(--white); font: inherit; }
.tada-form textarea { min-height: 120px; }
.tada-notice { margin-bottom: 24px; padding: 18px 22px; border-radius: 12px; background: var(--parchment); }

.site-footer { padding: 54px 0; color: rgba(255,255,255,.78); background: #0f1c14; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 40px; }
.site-footer a { color: var(--gold); }

@media (max-width: 850px) {
  .header-inner { position: relative; }
  .site-header .tada-menu-toggle { display: inline-flex; flex: 0 0 auto; }
  .site-header .header-cta { display: none; }
  .site-header .tada-site-nav { display: none; position: absolute; top: 100%; right: 0; width: min(320px, calc(100vw - 28px)); padding: 18px; background: var(--forest-dark); border: 1px solid rgba(255,255,255,.14); border-radius: 0 0 16px 16px; box-shadow: var(--shadow); }
  .site-header .tada-site-nav.is-open { display: block; }
  .site-header .tada-site-nav ul { display: grid; gap: 0; }
  .site-header .tada-site-nav li { border-bottom: 1px solid rgba(255,255,255,.12); }
  .site-header .tada-site-nav li a { display: block; padding: 12px 4px; }
  .site-header .tada-site-nav .nav-cta { border-bottom: 0; }
  .site-header .tada-site-nav .nav-cta a { display: inline-flex; width: 100%; margin-top: 16px; padding: 10px 22px; color: var(--forest-dark); }
  .site-header .tada-site-nav .mobile-nav-cta { display: inline-flex; width: 100%; margin-top: 16px; color: var(--forest-dark); }
  .section-grid, .cards, .post-grid { grid-template-columns: 1fr; }
  .hero { min-height: 760px; }
  .hero .wrap { justify-content: center; padding-top: 330px; }
  .hero-card { margin-bottom: 24px; background: rgba(20,37,27,.76); }
  .tada-form { grid-template-columns: 1fr; }
  .tada-form .full { grid-column: auto; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .wrap { width: min(100% - 28px, 1180px); }
  .header-inner { min-height: 70px; }
  .schedule li { grid-template-columns: 1fr; gap: 2px; }
  .footer-grid { grid-template-columns: 1fr; }
}
