/* Templates: the list and one template's page. Phone first. */
.tpage { position: relative; z-index: 1; width: 100%; max-width: 82rem; margin: 0 auto; padding: clamp(1rem, 3vw, 2rem) clamp(16px, 4vw, 48px) 4rem; }
.tpage .eyebrow { margin: 0 0 0.5rem; color: var(--gold-2); font-family: var(--pixel); font-size: 0.75rem; letter-spacing: 0.05em; }
[hidden] { display: none !important; }

/* Top of the list */
.thero { max-width: 44rem; }
.thero h1 { margin: 0; font-size: clamp(2.4rem, 7vw, 4rem); line-height: 1; }
.thero .lede { margin: 0.8rem 0 0; color: var(--white); font-size: clamp(1.05rem, 2.2vw, 1.25rem); font-weight: 300; }

/* Filter chips */
.tchips { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 1.6rem 0 1.2rem; }
.tchips button { padding: 0.45rem 0.9rem; border: 1px solid rgba(251, 191, 36, 0.4); border-radius: 99px; background: none; color: var(--gold-1); font: inherit; font-family: var(--pixel); font-size: 0.7rem; cursor: pointer; }
.tchips button[aria-pressed="true"] { border-color: transparent; background: linear-gradient(100deg, var(--gold-3), var(--gold-2), var(--gold-1)); color: #150e02; }

/* The grid of cards */
.tgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(9.5rem, 16rem)); justify-content: start; grid-auto-flow: dense; gap: 12px; align-items: start; }
@media (max-width: 599px) { .tgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.tcard { position: relative; display: flex; flex-direction: column; overflow: hidden; border: 1px solid rgba(251, 191, 36, 0.2); border-radius: 16px; background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015)); transition: border-color 0.2s, transform 0.2s; }
.tcard:hover { border-color: rgba(251, 191, 36, 0.7); transform: translateY(-3px); }
.tcard.wide { grid-column: span 2; }
.tcard .cover { position: absolute; inset: 0; z-index: 1; }
.tcard .tbody { display: flex; flex-direction: column; gap: 0.35rem; padding: 0.8rem 0.9rem 0.9rem; }
.tcard h2 { margin: 0; color: var(--white); font-size: 1.05rem; font-weight: 800; letter-spacing: -0.02em; line-height: 1.2; }
.tmeta { margin: 0; color: var(--muted); font-size: 0.8rem; }
.tmeta b { color: var(--gold-1); font-weight: 600; }
.ttype { margin: 0.1rem 0 0; color: var(--text); font-size: 0.86rem; line-height: 1.4; }
.ttype b { display: block; color: var(--gold-2); font-family: var(--pixel); font-size: 0.62rem; font-weight: 400; letter-spacing: 0.04em; }
.tcard .tact { position: relative; z-index: 2; display: flex; flex-wrap: wrap; align-items: center; gap: 0.3rem 0.8rem; margin-top: 0.4rem; }
.tdl { color: var(--muted); font-size: 0.8rem; text-decoration: underline; text-underline-offset: 0.2em; }
.tdl:hover { color: var(--gold-1); }

/* Preview picture (or the built placeholder while there is none) */
.tprev { position: relative; overflow: hidden; background: #0f0f13; }
.tprev.vertical { aspect-ratio: 9 / 16; }
.tprev.wide { aspect-ratio: 16 / 9; }
.tprev img.pic { width: 100%; height: 100%; object-fit: cover; display: block; }
.tprev .stage { position: absolute; inset: 0; aspect-ratio: auto; border-radius: 0; }
.tprev .stage img { width: 30%; }
.tprev.wide .stage img { width: 16%; }
.tprev .ptext { position: absolute; left: 8%; right: 8%; top: 12%; color: #fff; font-weight: 800; font-size: clamp(0.9rem, 2.4vw, 1.3rem); line-height: 1.1; text-align: center; text-shadow: 0 2px 10px rgba(0, 0, 0, 0.7); }
.tprev .len { position: absolute; right: 8px; bottom: 8px; z-index: 1; padding: 0.15rem 0.45rem; border-radius: 6px; background: rgba(0, 0, 0, 0.7); color: #fff; font-size: 0.72rem; font-weight: 600; }

/* Gold buttons */
.tbtn { display: inline-block; padding: 0.8rem 1.3rem; border: 0; border-radius: 10px; background: linear-gradient(100deg, var(--gold-3), var(--gold-2), var(--gold-1)); color: #150e02; font: inherit; font-weight: 800; text-align: center; text-decoration: none; cursor: pointer; box-shadow: 0 0 24px rgba(251, 158, 11, 0.4); }
.tbtn.small { padding: 0.5rem 0.85rem; font-size: 0.85rem; }
.tbtn.ghost { border: 1px solid rgba(251, 191, 36, 0.55); background: rgba(251, 191, 36, 0.06); color: var(--gold-1); box-shadow: none; }
.tbtn:hover { filter: brightness(1.06); }

/* One template's page */
.tone { display: grid; gap: clamp(1.4rem, 4vw, 3rem); align-items: start; }
@media (min-width: 860px) { .tone { grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); } .tone.is-wide { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); } }
.tone .tprev { border: 1px solid rgba(251, 191, 36, 0.35); border-radius: 20px; box-shadow: 0 0 44px rgba(251, 158, 11, 0.14); }
.tone .tprev.vertical { width: min(100%, 24rem, calc(52vh * 0.5625)); margin-inline: auto; }
.tone h1 { margin: 0; font-size: clamp(2.2rem, 6vw, 3.6rem); line-height: 1.02; }
.tone .chipsrow { display: flex; flex-wrap: wrap; gap: 0.4rem; margin: 0.9rem 0 1.2rem; }
.tone .chipsrow span { padding: 0.3rem 0.7rem; border: 1px solid rgba(251, 191, 36, 0.4); border-radius: 99px; color: var(--gold-1); font-family: var(--pixel); font-size: 0.66rem; }
.whattype { margin: 0 0 1.3rem; padding: 1rem 1.1rem; border-left: 3px solid var(--gold-2); border-radius: 0 12px 12px 0; background: rgba(251, 191, 36, 0.07); }
.whattype b { display: block; margin-bottom: 0.3rem; color: var(--gold-2); font-family: var(--pixel); font-size: 0.7rem; font-weight: 400; letter-spacing: 0.04em; }
.whattype p { margin: 0; color: var(--white); font-size: 1.05rem; line-height: 1.45; }
.open-row .tbtn { width: 100%; padding: 1rem 1.4rem; font-size: 1.1rem; }
@media (min-width: 560px) { .open-row .tbtn { width: auto; min-width: 18rem; } }
.dl-line { margin: 0.9rem 0 0; color: var(--muted); font-size: 0.9rem; line-height: 1.5; }
.dl-line a { color: var(--gold-1); font-weight: 600; }
.box { margin-top: 1.2rem; padding: 1.1rem 1.2rem; border: 1px solid rgba(251, 191, 36, 0.5); border-radius: 16px; background: linear-gradient(180deg, rgba(251, 191, 36, 0.1), rgba(251, 191, 36, 0.03)); }
.box .big { margin: 0 0 0.3rem; color: var(--white); font-size: 1.15rem; font-weight: 800; }
.box p { margin: 0 0 0.9rem; color: var(--text); font-size: 0.95rem; line-height: 1.45; }
.box .row { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0; }
.box .note { margin: 0.8rem 0 0; color: var(--muted); font-size: 0.85rem; }
.box img.dino { float: right; width: 3rem; margin: 0 0 0.4rem 0.8rem; image-rendering: pixelated; }

/* How it works, three small steps */
.steps3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-top: 1.6rem; }
.steps3 div { padding: 0.75rem; border: 1px solid rgba(251, 191, 36, 0.2); border-radius: 12px; background: rgba(255, 255, 255, 0.03); }
.steps3 b { display: block; color: var(--gold-1); font-family: var(--pixel); font-size: 0.65rem; font-weight: 400; }
.steps3 span { display: block; margin-top: 0.25rem; color: var(--white); font-size: 0.86rem; line-height: 1.3; }
.more-t { margin-top: clamp(2.5rem, 6vw, 4rem); }
.more-t > h2 { margin: 0 0 1rem; font-size: clamp(1.3rem, 3vw, 1.8rem); }
.tpage .none { color: var(--muted); }
