/*
Theme Name: Tarot Deck
Description: Storefront and guide theme for tarotdeck.co
Version: 1.4.0
Requires PHP: 7.4
Text Domain: tarotdeck
*/

:root {
  --ink: #131a2e;
  --ink-deep: #0b101e;
  --gold: #c8a25a;
  --gold-soft: #e3c98f;
  --cream: #f7f3ea;
  --wine: #40172a;
  --text: #171717;
  --muted: #5d5a55;
  --line: #e2dccd;
  --display: "Fraunces", Georgia, serif;
  --serif: "EB Garamond", Georgia, serif;
  --sans: "Inter", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; font-family: var(--sans); font-size: 16px; line-height: 1.65; color: var(--text); background: #fff; -webkit-font-smoothing: antialiased; }
img, svg { max-width: 100%; }
a { color: inherit; }
.td-wrap { max-width: 1010px; margin: 0 auto; padding: 0 24px; }

/* Top strip */
.td-strip { background: var(--gold); color: var(--ink-deep); display: flex; align-items: center; justify-content: center; gap: 16px; padding: 7px 16px; font-family: var(--serif); font-size: 15px; letter-spacing: .04em; }

/* Buttons */
.td-btn { display: inline-block; background: var(--ink); color: #fff; font-family: var(--serif); font-size: 14px; letter-spacing: .16em; text-transform: uppercase; text-decoration: none; padding: 12px 20px; border: 1px solid var(--ink); border-radius: 2px; cursor: pointer; }
.td-btn:hover { background: var(--ink-deep); }
.td-btn-small { padding: 5px 12px; font-size: 12px; }
.td-btn-line { background: transparent; border-color: rgba(255,255,255,.75); color: #fff; }
.td-btn-line:hover { background: rgba(255,255,255,.1); }
.td-btn-gold { background: var(--gold); border-color: var(--gold); color: var(--ink-deep); }
.td-btn-gold:hover { background: var(--gold-soft); }

/* Header */
.td-header { background: var(--ink-deep); position: sticky; top: 0; z-index: 20; }
.td-header-in { max-width: 1010px; margin: 0 auto; padding: 0 24px; height: 60px; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; }
.td-nav { display: flex; gap: 26px; }
.td-nav-right { justify-content: flex-end; }
.td-nav a, .td-mobile a { color: #fff; text-decoration: none; font-family: var(--serif); font-size: 13px; letter-spacing: .18em; text-transform: uppercase; }
.td-nav a:hover { color: var(--gold-soft); }
.td-logo { color: #fff; text-decoration: none; font-family: var(--serif); font-size: 25px; letter-spacing: .2em; padding: 0 28px; white-space: nowrap; }
.td-logo span { color: var(--gold); }
.td-menu-btn { display: none; justify-self: end; background: none; border: 1px solid rgba(255,255,255,.5); color: #fff; font-family: var(--serif); font-size: 13px; letter-spacing: .16em; text-transform: uppercase; padding: 6px 12px; border-radius: 2px; }
.td-mobile { position: absolute; top: 100%; left: 0; right: 0; background: var(--ink-deep); display: flex; flex-direction: column; padding: 6px 24px 14px; border-top: 1px solid rgba(255,255,255,.12); box-shadow: 0 14px 24px rgba(0,0,0,.35); }
.td-mobile a { padding: 13px 0; border-bottom: 1px solid rgba(255,255,255,.08); }
.td-mobile a:last-child { border-bottom: 0; }
.td-mobile[hidden] { display: none; }

/* Article hero */
.td-hero { background: var(--ink); color: #fff; }
.td-hero-in { display: grid; grid-template-columns: 300px 1fr; gap: 30px; align-items: start; padding-top: 28px; padding-bottom: 28px; }
.td-hero-text { padding-top: 14px; }
.td-stars { color: var(--gold); letter-spacing: .5em; font-size: 12px; margin-bottom: 26px; }
.td-crumbs { font-size: 12px; color: rgba(255,255,255,.6); margin-bottom: 14px; }
.td-crumbs a { color: var(--gold-soft); text-decoration: underline; text-decoration-color: rgba(227,201,143,.5); text-underline-offset: 3px; }
.td-crumbs i { margin: 0 8px; font-style: normal; }
.td-hero h1 { font-family: var(--display); font-weight: 600; font-size: 31px; line-height: 1.28; margin: 0; }
.td-hero-art { background: #d9a760; min-height: 400px; display: flex; align-items: center; justify-content: center; position: relative; overflow: hidden; }
.td-hero-art::before { content: ""; position: absolute; width: 360px; height: 360px; border-radius: 50%; background: linear-gradient(160deg, #8f86c9, #b99bb5); }
.td-hero-art::after { content: ""; position: absolute; width: 130px; height: 170px; left: 9%; bottom: 14%; border-radius: 55% 45% 60% 40%; background: #9aae5a; }
.td-hero-art .td-card { position: relative; z-index: 1; width: 212px; height: auto; filter: drop-shadow(0 10px 18px rgba(11,16,30,.35)); }
.td-hero-art.is-plain { min-height: 240px; }
.td-hero-art.is-plain::before { width: 240px; height: 240px; }
.td-hero-art.is-plain .td-card { width: 120px; }

/* Card photos */
img.td-card-photo { height: auto; border-radius: 4.5% / 2.7%; background: #fff; box-shadow: 0 6px 16px rgba(11,16,30,.35); display: block; }
.td-tile img.td-card-photo { width: 62%; margin-bottom: 18px; }
.td-tool-result img.td-card-photo { margin: 0 auto; }
.td-tool-cards img.td-card-photo { margin: 0; }
.td-promo-art img.td-card-photo, .td-sheet-art img.td-card-photo { box-shadow: 0 6px 16px rgba(0,0,0,.4); }

/* Article body */
.td-article { max-width: 798px; margin: 0 auto; padding: 34px 24px 60px; }
.td-article h2 { font-family: var(--display); font-weight: 600; font-size: 29px; line-height: 1.3; margin: 46px 0 14px; }
.td-article h3 { font-family: var(--serif); font-style: italic; font-weight: 500; font-size: 26px; line-height: 1.3; margin: 34px 0 10px; }
.td-article h4 { font-family: var(--serif); font-weight: 500; font-size: 21px; margin: 26px 0 6px; }
.td-article p, .td-article li { font-size: 16px; }
.td-article p { margin: 0 0 16px; }
.td-article a { color: #8a6a24; text-underline-offset: 3px; }
.td-article a:hover { color: var(--ink); }
.td-article ul, .td-article ol { padding-left: 22px; margin: 0 0 18px; }
.td-article li { margin-bottom: 6px; }
.td-article blockquote { margin: 30px auto; padding: 0 20px; text-align: center; max-width: 620px; }
.td-article blockquote p { font-family: var(--serif); font-style: italic; font-size: 24px; line-height: 1.4; color: #a8853f; margin: 0; }
.td-article blockquote::after { content: "\201D"; display: block; font-family: var(--display); font-size: 54px; line-height: .8; margin-top: 14px; color: #dfd2b4; }
.td-article table { width: 100%; border-collapse: collapse; margin: 0 0 24px; font-size: 15px; background: var(--cream); }
.td-article th { text-align: left; font-weight: 600; padding: 10px 12px; border-bottom: 1px solid var(--gold); }
.td-article td { padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }

/* Keyword tables */
.td-kw { display: grid; background: var(--cream); margin: 4px 0 22px; }
.td-kw-2 { grid-template-columns: repeat(2, 1fr); }
.td-kw-3 { grid-template-columns: repeat(3, 1fr); }
.td-kw-4 { grid-template-columns: repeat(4, 1fr); }
.td-kw > div { display: flex; flex-direction: column; }
.td-kw b { font-weight: 600; font-size: 14px; padding: 11px 12px; border-bottom: 1px solid var(--gold); }
.td-kw span { font-size: 14px; line-height: 1.55; padding: 11px 12px 14px; color: #2b2b2b; }
.td-jump { font-size: 13px; color: var(--muted); }

/* Spread diagrams */
.td-spread { background: var(--cream); margin: 22px 0 28px; padding: 22px 16px; text-align: center; }
.td-spread svg { width: 100%; height: auto; }

/* Deck photos */
.td-deckphoto { background: var(--cream); margin: 22px 0 28px; padding: 26px 18px 16px; text-align: center; }
.td-deckphoto-row { display: flex; justify-content: center; align-items: flex-start; gap: 18px; }
.td-deckphoto-row img.td-card-photo { width: 150px; max-width: 28%; box-shadow: 0 5px 14px rgba(11,16,30,.25); }
.td-deckphoto figcaption { font-size: 13px; color: var(--muted); margin-top: 14px; }

/* Promo block */
.td-promo { display: grid; grid-template-columns: 1fr 1fr; background: var(--cream); margin: 34px 0; }
.td-promo-art { background: var(--wine); display: flex; align-items: center; justify-content: center; padding: 26px; }
.td-promo-art .td-card { width: 120px; transform: rotate(-6deg); }
.td-promo-body { padding: 28px 30px; }
.td-article .td-promo-title { font-family: var(--display); font-weight: 600; font-size: 22px; line-height: 1.3; margin: 0 0 10px; }
.td-promo-body p { font-size: 15px; }
.td-article .td-promo a.td-btn { color: #fff; text-decoration: none; margin-top: 4px; }

/* Cheat sheet */
.td-sheet { display: grid; grid-template-columns: 170px 1fr; gap: 26px; background: var(--ink); color: #fff; padding: 28px; }
.td-sheet-art .td-card { width: 100%; }
.td-sheet dl { margin: 0; display: grid; grid-template-columns: 150px 1fr; gap: 0; align-content: start; }
.td-sheet dt { font-family: var(--serif); font-style: italic; color: var(--gold-soft); font-size: 16px; padding: 7px 0; border-bottom: 1px solid rgba(255,255,255,.14); }
.td-sheet dd { margin: 0; font-size: 14px; padding: 8px 0; border-bottom: 1px solid rgba(255,255,255,.14); }

/* Bands */
.td-band-title { font-family: var(--display); font-weight: 600; font-size: 26px; line-height: 1.25; margin: 0 0 6px; color: #fff; }
.td-band-title.td-dark { color: var(--text); text-align: center; margin: 44px 0 20px; }
.td-band-sub { font-family: var(--serif); font-style: italic; font-size: 20px; margin: 0 0 20px; color: var(--gold-soft); }
.td-quicknav { background: var(--ink); color: #fff; text-align: center; padding: 50px 0 54px; }
.td-quicknav .td-stars { margin-bottom: 14px; }
.td-quicknav ul { list-style: none; padding: 0; margin: 26px auto 30px; max-width: 760px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 9px 20px; }
.td-quicknav li { font-size: 14px; }
.td-quicknav li a { color: #fff; text-decoration: none; }
.td-quicknav li a:hover { color: var(--gold-soft); }
.td-quicknav li.is-current { color: var(--gold-soft); }
.td-quicknav li em { font-style: normal; opacity: .8; }
.td-quicknav .td-btn { margin: 4px 6px; }

.td-learn { background: var(--ink-deep); color: #fff; display: grid; grid-template-columns: 1fr 1fr; align-items: center; overflow: hidden; }
.td-learn-art { display: flex; gap: 18px; justify-content: flex-end; padding: 0 40px 0 0; height: 230px; align-items: center; opacity: .55; }
.td-learn-art .td-card { width: 118px; flex: none; transform: rotate(-14deg) translateY(18px); }
.td-learn-body { padding: 40px 24px; }

/* Hub and card grid */
.td-hub { padding-top: 30px; }
.td-pills { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; }
.td-pills a { background: var(--ink); color: #fff; text-decoration: none; font-family: var(--serif); font-size: 12px; letter-spacing: .16em; text-transform: uppercase; padding: 6px 14px; border-radius: 20px; }
.td-hub-one .td-band-title { display: none; }
.td-hub-one { padding-top: 34px; }
.td-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.td-tile { background: var(--ink-deep); color: #fff; text-decoration: none; text-align: center; padding: 26px 16px 22px; display: flex; flex-direction: column; align-items: center; }
.td-tile .td-card { width: 62%; margin-bottom: 18px; }
.td-tile-name { font-family: var(--serif); font-style: italic; font-size: 21px; line-height: 1.2; color: var(--gold-soft); }
.td-tile-meta { font-size: 12px; margin-top: 8px; opacity: .8; }
.td-tile:hover { background: var(--ink); }

/* Home */
.td-home-hero { background: var(--ink); color: #fff; position: relative; overflow: hidden; text-align: center; min-height: 600px; display: flex; flex-direction: column; justify-content: center; }
.td-home-cards { position: absolute; inset: 0; display: flex; justify-content: center; align-items: center; gap: 22px; opacity: .3; }
.td-home-cards .td-card { width: 210px; flex: none; }
.td-home-cards .td-card:nth-child(odd) { transform: translateY(46px); }
.td-home-hero-text { position: relative; padding: 40px 24px 90px; }
.td-home-hero h1 { font-family: var(--display); font-weight: 600; font-size: 29px; line-height: 1.3; margin: 0 0 14px; }
.td-home-tabs { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); width: 100%; max-width: 1140px; display: grid; grid-template-columns: repeat(3, 1fr); border-bottom: 3px solid var(--gold); }
.td-home-tabs a { color: #fff; text-decoration: none; font-family: var(--serif); font-size: 13px; letter-spacing: .18em; text-transform: uppercase; padding: 20px 12px; }
.td-home-tabs a:first-child { background: rgba(200,162,90,.2); }
.td-home-tabs b { color: var(--gold-soft); font-weight: 400; margin-right: 8px; }
.td-sec { padding: 60px 0 66px; text-align: center; }
.td-sec-cream { background: var(--cream); }
.td-stars-gold { margin-bottom: 14px; }
.td-sec-title { font-family: var(--display); font-weight: 600; font-size: 29px; margin: 0 0 4px; }
.td-sec-sub { font-family: var(--serif); font-style: italic; font-size: 20px; margin: 0 0 30px; color: #333; }
.td-feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.td-feature { background: var(--ink-deep); color: var(--gold-soft); text-decoration: none; padding: 34px 20px 22px; display: flex; flex-direction: column; align-items: center; min-height: 400px; justify-content: space-between; }
.td-feature .td-card { width: 150px; }
.td-feature span { font-family: var(--serif); font-style: italic; font-size: 22px; align-self: flex-start; text-align: left; }
.td-feature:hover { background: var(--ink); }
.td-lib { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; text-align: left; }
.td-lib a { background: #fff; border: 1px solid var(--line); padding: 22px; text-decoration: none; display: flex; flex-direction: column; gap: 6px; }
.td-lib a:hover { border-color: var(--gold); }
.td-lib b { font-family: var(--display); font-weight: 600; font-size: 19px; }
.td-lib span { font-size: 14px; color: var(--muted); }
.td-sec .td-grid-sec .td-band-title { display: none; }

/* Tools */
.td-tool { background: var(--ink); color: #fff; padding: 34px 26px; margin: 22px 0 30px; text-align: center; }
.td-tool-result { margin-top: 26px; display: none; }
.td-tool-result.is-on { display: block; }
.td-tool-result .td-card { width: 170px; }
.td-tool-result .td-card.is-rev { transform: rotate(180deg); }
.td-tool-cards { display: flex; gap: 22px; justify-content: center; flex-wrap: wrap; }
.td-tool-verdict { font-family: var(--display); font-weight: 600; font-size: 44px; line-height: 1.1; color: var(--gold-soft); margin: 18px 0 4px; }
.td-tool-name { font-family: var(--serif); font-style: italic; font-size: 24px; margin: 12px 0 14px; }
.td-tool a.td-link { color: var(--gold-soft); }
.td-tool-fields { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-bottom: 18px; }
.td-tool label { display: flex; flex-direction: column; gap: 4px; font-size: 13px; text-align: left; }
.td-tool select, .td-tool input { font: inherit; font-size: 16px; padding: 9px 10px; border: 1px solid #c9c2b2; border-radius: 2px; background: #fff; color: var(--text); min-width: 110px; }
.td-tool select:focus, .td-tool input:focus { outline: none; border-color: var(--gold); }
.td-tool-note { font-size: 14px; opacity: .85; margin: 12px 0 0; }

/* Footer */
.td-footer { background: var(--cream); padding: 50px 0 30px; }
.td-footer-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 30px; }
.td-footer-head { font-weight: 600; font-size: 14px; margin: 0 0 14px; }
.td-footer a { display: block; font-size: 14px; text-decoration: none; margin-bottom: 9px; color: #2b2b2b; }
.td-footer a:hover { color: #8a6a24; }
.td-copy { text-align: center; font-size: 13px; color: var(--muted); margin: 44px 0 0; }
.td-footer .td-copy a { display: inline; font-size: 13px; margin: 0; color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }

@media (max-width: 860px) {
  .td-nav { display: none; }
  .td-menu-btn { display: block; }
  .td-header-in { grid-template-columns: 1fr auto; }
  .td-logo { padding: 0; font-size: 21px; }
  .td-hero-in { grid-template-columns: 1fr; gap: 20px; }
  .td-hero-text { padding-top: 0; }
  .td-stars { margin-bottom: 14px; }
  .td-hero h1 { font-size: 27px; }
  .td-hero-art { min-height: 300px; }
  .td-hero-art::before { width: 260px; height: 260px; }
  .td-hero-art .td-card { width: 160px; }
  .td-article h2 { font-size: 25px; }
  .td-article h3 { font-size: 23px; }
  .td-kw-3, .td-kw-4 { grid-template-columns: 1fr; }
  .td-promo, .td-learn, .td-sheet { grid-template-columns: 1fr; }
  .td-sheet-art { max-width: 130px; }
  .td-sheet dl { grid-template-columns: 1fr; }
  .td-sheet dt { border-bottom: 0; padding-bottom: 0; }
  .td-learn-art { display: none; }
  .td-quicknav ul { grid-template-columns: repeat(2, 1fr); }
  .td-grid, .td-feature-grid, .td-lib { grid-template-columns: repeat(2, 1fr); }
  .td-feature { min-height: 300px; }
  .td-feature .td-card { width: 110px; }
  .td-footer-cols { grid-template-columns: repeat(2, 1fr); }
  .td-home-hero { min-height: 520px; }
  .td-home-cards { opacity: .13; }
  .td-home-cards .td-card { width: 170px; }
  .td-home-hero-text { padding-bottom: 110px; }
  .td-promo-art { padding: 20px; }
  .td-promo-art .td-card { width: 96px; }
  .td-article .td-promo a.td-btn { font-size: 13px; letter-spacing: .12em; padding: 12px 14px; }
  .td-home-tabs a { font-size: 11px; letter-spacing: .1em; padding: 16px 6px; }
  .td-article table { display: block; overflow-x: auto; }
}
