/* ==========================================================================
   LevAnte — Test del Síndrome del Titanic
   ========================================================================== */
.tt-head { padding-top: clamp(120px, 11vw, 168px); }
.tt-head .h1 { max-width: 14ch; }
.tt-body { padding-top: clamp(16px, 2vw, 32px); }
.tt-grid { display: grid; grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); gap: clamp(32px, 5vw, 88px); align-items: start; }

.tt-progress { position: sticky; top: 84px; z-index: 5; display: flex; align-items: center; gap: 14px; padding: 12px 0; background: var(--paper); }
.tt-bar { flex: 1; height: 3px; background: var(--line); border-radius: 3px; overflow: hidden; }
.tt-bar i { display: block; height: 100%; width: 0; background: var(--sandia); transition: width .5s var(--ease-out); }
.tt-count { font-size: 13px; font-weight: 500; color: var(--stone); font-variant-numeric: tabular-nums; min-width: 48px; text-align: right; }

.tt-q { border: 0; margin: 0; padding: clamp(24px, 3vw, 36px) 0; border-top: 1px solid var(--line); transition: opacity .3s; }
.tt-q legend { display: grid; grid-template-columns: 44px 1fr; gap: 8px; padding: 0; margin-bottom: 18px; float: left; width: 100%; }
.tt-q legend + * { clear: both; }
.tt-n { font-family: var(--serif); font-size: 22px; color: var(--sandia); line-height: 1.2; }
.tt-text { font-family: var(--serif); font-size: clamp(21px, 1.9vw, 27px); line-height: 1.22; letter-spacing: -0.005em; }
.tt-q.is-done .tt-text { color: var(--stone); transition: color .3s; }
.tt-q.is-done:hover .tt-text, .tt-q.is-done:focus-within .tt-text { color: var(--ink); }
.tt-q.is-done .tt-scale label:not(:has(input:checked)) { border-color: rgba(11,11,11,.07); }
.tt-q.is-missing:not(.is-done) .tt-n { text-decoration: underline; text-underline-offset: 6px; }
.tt-q.is-missing:not(.is-done) { border-top-color: var(--sandia); }

.tt-scale { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 8px; padding-left: 52px; }
.tt-scale label { position: relative; display: grid; justify-items: center; gap: 10px; padding: 14px 6px 12px; border: 1px solid var(--line); border-radius: var(--radius-md); cursor: pointer; text-align: center; transition: border-color .2s, background-color .2s; }
.tt-scale label:hover { border-color: var(--ink); }
.tt-scale input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.tt-dot { width: 16px; height: 16px; border-radius: 50%; border: 1.5px solid var(--kaki-deep); transition: border-color .2s, box-shadow .2s; }
.tt-opt { font-size: 12.5px; line-height: 1.3; color: var(--stone); }
.tt-scale label:has(input:checked) { background: var(--ink); border-color: var(--ink); }
.tt-scale label:has(input:checked) .tt-opt { color: var(--paper); }
.tt-scale label:has(input:checked) .tt-dot { border-color: var(--sandia); box-shadow: inset 0 0 0 4px var(--ink), inset 0 0 0 10px var(--sandia); }
.tt-scale label:has(input:focus-visible) { outline: 2px solid var(--sandia); outline-offset: 3px; }

.tt-submit { display: grid; gap: 12px; justify-items: start; padding-top: 32px; border-top: 1px solid var(--line); }
.tt-error { color: var(--sandia); font-weight: 500; }

.tt-side { position: sticky; top: 110px; }
.tt-side-card { background: var(--nude); border-radius: var(--radius-xl); padding: clamp(24px, 2.4vw, 36px); display: grid; gap: 20px; }
.tt-dims { display: grid; gap: 16px; }
.tt-dims li { display: grid; gap: 4px; padding-left: 16px; position: relative; }
.tt-dims li::before { content: ""; position: absolute; left: 0; top: .6em; width: 8px; height: 2px; background: var(--sandia); }
.tt-dims b { font-family: var(--serif); font-weight: 400; font-size: 22px; }
.tt-dims span { font-size: 14.5px; color: var(--stone); }
.tt-note { color: var(--stone); padding-top: 16px; border-top: 1px solid var(--line); }

/* Resultado */
.tt-result { padding: 0 var(--frame) var(--frame); outline: none; }
.tt-result-card { background: var(--ink); color: var(--paper); border-radius: var(--radius-xl); padding: clamp(32px, 5vw, 80px); display: grid; gap: clamp(32px, 4vw, 56px); opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease-out), transform .7s var(--ease-out); }
.tt-result.is-in .tt-result-card { opacity: 1; transform: none; }
.tt-result-head { display: grid; gap: 14px; max-width: 760px; }
.tt-result .eyebrow { color: var(--kaki); }
.tt-score { font-family: var(--serif); line-height: .9; }
.tt-score-n { font-size: clamp(88px, 11vw, 168px); }
.tt-score-of { font-size: clamp(22px, 2vw, 30px); color: rgba(244, 242, 238, .5); margin-left: 8px; }
.tt-verdict em { color: var(--sandia); }
.tt-summary { color: rgba(244, 242, 238, .74); }
.tt-bars { display: grid; gap: 18px; max-width: 760px; }
.tt-barrow { display: grid; grid-template-columns: 220px 1fr 44px; gap: 18px; align-items: center; }
.tt-bar-name { font-size: 15px; font-weight: 500; }
.tt-bar-name em { font-style: normal; font-weight: 400; color: var(--sandia); }
.tt-bar-track { height: 8px; border-radius: 8px; background: rgba(244, 242, 238, .12); overflow: hidden; }
.tt-bar-track i { display: block; height: 100%; width: 0; background: var(--nude); border-radius: 8px; transition: width 1.1s var(--ease-out) .2s; }
.tt-result.is-in .tt-bar-track i { width: var(--w); }
.tt-barrow.is-weak .tt-bar-track i { background: var(--sandia); }
.tt-bar-val { font-family: var(--serif); font-size: 24px; text-align: right; font-variant-numeric: tabular-nums; }
.tt-next { display: grid; gap: 22px; padding-top: clamp(24px, 3vw, 40px); border-top: 1px solid var(--line-on-ink); max-width: 760px; }
.tt-next-text { font-size: clamp(17px, 1.3vw, 19px); line-height: 1.6; color: rgba(244, 242, 238, .86); }
.tt-next-ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.tt-restart { justify-self: start; font-size: 13.5px; color: rgba(244, 242, 238, .6); border-bottom: 1px solid var(--line-on-ink); padding-bottom: 2px; }
.tt-restart:hover { color: var(--paper); }

@media (max-width: 1100px) {
  .tt-grid { grid-template-columns: minmax(0, 1fr); }
  .tt-side { position: static; order: -1; }
}
@media (max-width: 720px) {
  .tt-progress { top: 64px; }
  .tt-scale { padding-left: 0; grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .tt-scale label { grid-template-columns: 16px 1fr; justify-items: start; align-items: center; text-align: left; padding: 12px 14px; gap: 12px; }
  .tt-opt { font-size: 14.5px; }
  .tt-q legend { grid-template-columns: 34px 1fr; }
  .tt-barrow { grid-template-columns: 1fr 40px; }
  .tt-bar-name { grid-column: 1 / -1; }
}
@media (prefers-reduced-motion: reduce) {
  .tt-result-card, .tt-bar-track i, .tt-bar i { transition: none; }
}
