﻿:root {
      color-scheme: light;
      --ink: #17111f;
      --muted: #665f75;
      --line: #1d1429;
      --paper: #fff6d8;
      --panel: #ffffff;
      --peach: #ff7a3d;
      --mint: #1fcf8f;
      --blue: #7a2cff;
      --lemon: #ffcf1d;
      --rose: #ff3f85;
      --violet: #7a2cff;
      --shadow: 0 18px 0 rgba(23, 17, 31, .14);
      --radius: 8px;
      font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    }

    * {
      box-sizing: border-box;
    }

    body {
      margin: 0;
      min-height: 100vh;
      color: var(--ink);
      background:
        linear-gradient(135deg, rgba(255, 207, 29, .28) 0 12px, transparent 12px 24px),
        linear-gradient(180deg, #fff6d8 0%, #eafff6 38%, #fff0f7 76%, #fff6d8 100%);
      background-size: 48px 48px, auto;
    }

    button,
    input {
      font: inherit;
    }

    button {
      border: 0;
      cursor: pointer;
    }

    .shell {
      width: min(1180px, calc(100% - 32px));
      margin: 0 auto;
      padding: 22px 0 48px;
    }

    .topbar {
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 16px;
      position: sticky;
      top: 10px;
      z-index: 10;
      margin: 0 0 20px;
      padding: 10px 12px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      background: rgba(255, 255, 255, .88);
      box-shadow: 5px 5px 0 var(--ink);
      backdrop-filter: blur(12px);
    }

    .brand {
      display: flex;
      align-items: center;
      gap: 10px;
      font-weight: 900;
      font-size: 22px;
      letter-spacing: 0;
    }

    .brand-mark {
      display: grid;
      place-items: center;
      width: 44px;
      height: 44px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      overflow: hidden;
      background: var(--violet);
      box-shadow: 4px 4px 0 var(--ink);
    }

    .brand-mark img {
      width: 100%;
      height: 100%;
      object-fit: cover;
    }

    .top-actions {
      display: flex;
      align-items: center;
      gap: 10px;
      flex-wrap: wrap;
    }

    .ghost-link {
      color: var(--ink);
      text-decoration: none;
      font-weight: 900;
      padding: 9px 12px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      background: var(--lemon);
      box-shadow: 3px 3px 0 var(--ink);
    }

    .hero {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(340px, 470px);
      gap: 36px;
      align-items: center;
      min-height: clamp(560px, 82vh, 760px);
      padding: 18px 0 38px;
    }

    .hero h1 {
      margin: 0;
      max-width: 850px;
      font-size: clamp(42px, 7vw, 86px);
      line-height: .95;
      letter-spacing: 0;
      text-shadow: 4px 4px 0 rgba(255, 207, 29, .9);
    }

    .hero-copy {
      margin: 20px 0 0;
      max-width: 670px;
      color: #35263e;
      font-size: clamp(18px, 2vw, 22px);
      line-height: 1.45;
      padding: 14px 16px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      background: rgba(255, 255, 255, .76);
      box-shadow: 5px 5px 0 rgba(23, 17, 31, .18);
    }

    .hero-actions {
      display: flex;
      align-items: center;
      gap: 12px;
      flex-wrap: wrap;
      margin-top: 26px;
    }

    .primary-btn,
    .secondary-btn,
    .answer-btn,
    .tiny-btn {
      min-height: 44px;
      border-radius: var(--radius);
      font-weight: 800;
      transition: transform .15s ease, box-shadow .15s ease, background .15s ease;
    }

    .primary-btn {
      padding: 13px 18px;
      color: white;
      border: 2px solid var(--ink);
      background: var(--rose);
      box-shadow: 5px 5px 0 var(--ink);
    }

    .primary-btn:hover,
    .secondary-btn:hover,
    .answer-btn:hover,
    .tiny-btn:hover {
      transform: translateY(-1px);
    }

    .secondary-btn {
      padding: 12px 16px;
      color: var(--ink);
      border: 2px solid var(--ink);
      background: var(--lemon);
      box-shadow: 5px 5px 0 var(--ink);
    }

    .tiny-btn {
      min-height: 38px;
      padding: 9px 12px;
      color: var(--ink);
      border: 2px solid var(--ink);
      background: white;
      box-shadow: 3px 3px 0 var(--ink);
    }

    .stat-strip {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 10px;
      margin-top: 34px;
      max-width: 720px;
    }

    .stat {
      padding: 14px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      background: white;
      box-shadow: 4px 4px 0 var(--ink);
    }

    .stat strong {
      display: block;
      font-size: 24px;
      color: var(--rose);
    }

    .stat span {
      color: var(--muted);
      font-size: 13px;
      font-weight: 700;
    }

    .sample-card {
      position: relative;
      overflow: hidden;
      padding: 22px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      background: white;
      box-shadow: var(--shadow);
    }

    .sample-card::before {
      content: "";
      position: absolute;
      inset: 0 0 auto;
      height: 12px;
      background: linear-gradient(90deg, var(--peach), var(--lemon), var(--mint), var(--blue), var(--rose));
    }

    .hero-art {
      position: relative;
      display: grid;
      place-items: center;
      min-height: 470px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      overflow: hidden;
      background:
        linear-gradient(45deg, rgba(255, 255, 255, .16) 0 18px, transparent 18px 36px),
        linear-gradient(135deg, #5516aa, #a31fff);
      box-shadow: 10px 10px 0 var(--ink);
    }

    .hero-icon {
      width: min(86%, 410px);
      aspect-ratio: 1;
      object-fit: contain;
      filter: drop-shadow(0 20px 22px rgba(22, 8, 42, .35));
      transform: rotate(-4deg);
    }

    .burst {
      position: absolute;
      z-index: 2;
      display: grid;
      place-items: center;
      width: 74px;
      height: 74px;
      border: 3px solid var(--ink);
      border-radius: 50%;
      font-size: 54px;
      line-height: 1;
      font-weight: 950;
      box-shadow: 5px 5px 0 var(--ink);
    }

    .burst-left {
      left: 18px;
      top: 72px;
      background: var(--lemon);
      transform: rotate(-12deg);
    }

    .burst-right {
      right: 18px;
      bottom: 96px;
      color: white;
      background: var(--rose);
      transform: rotate(12deg);
    }

    .hero-sticker {
      position: absolute;
      z-index: 3;
      max-width: 230px;
      padding: 10px 13px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background: white;
      box-shadow: 5px 5px 0 var(--ink);
      font-weight: 950;
      text-align: center;
    }

    .sticker-top {
      top: 24px;
      right: 34px;
      background: var(--mint);
      transform: rotate(5deg);
    }

    .sticker-bottom {
      left: 24px;
      bottom: 26px;
      background: var(--lemon);
      transform: rotate(-4deg);
    }

    .sample-label {
      margin-top: 12px;
      color: var(--muted);
      font-size: 13px;
      font-weight: 900;
      text-transform: uppercase;
    }

    .sample-title {
      margin: 12px 0 12px;
      font-size: 32px;
      line-height: 1.03;
      font-weight: 950;
    }

    .meter {
      display: grid;
      gap: 9px;
      margin-top: 18px;
    }

    .meter-row {
      display: grid;
      grid-template-columns: 112px 1fr 44px;
      gap: 8px;
      align-items: center;
      color: var(--muted);
      font-size: 13px;
      font-weight: 800;
    }

    .bar {
      height: 10px;
      overflow: hidden;
      border-radius: 999px;
      background: #eceef5;
    }

    .bar span {
      display: block;
      height: 100%;
      border-radius: 999px;
      background: linear-gradient(90deg, var(--mint), var(--violet));
    }

    .section-head {
      display: flex;
      align-items: end;
      justify-content: space-between;
      gap: 16px;
      margin: 14px 0 16px;
    }

    .section-head h2 {
      margin: 0;
      font-size: clamp(28px, 4vw, 42px);
      line-height: 1;
      text-shadow: 3px 3px 0 var(--lemon);
    }

    .section-head p {
      margin: 0;
      max-width: 480px;
      color: var(--muted);
      line-height: 1.45;
    }

    .daily {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(280px, 360px);
      gap: 18px;
      align-items: center;
      margin: 0 0 48px;
      padding: 20px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background:
        linear-gradient(90deg, rgba(255, 63, 133, .12) 0 18px, transparent 18px 36px),
        #fff;
      box-shadow: 10px 10px 0 var(--ink);
    }

    .daily-copy h2 {
      margin: 10px 0 12px;
      font-size: clamp(34px, 5vw, 58px);
      line-height: .96;
      text-shadow: 3px 3px 0 rgba(31, 207, 143, .7);
    }

    .daily-copy p {
      margin: 0;
      max-width: 680px;
      color: #343744;
      font-size: clamp(18px, 2vw, 22px);
      line-height: 1.45;
    }

    .daily .result-actions {
      margin-top: 18px;
    }

    .daily-card-wrap {
      width: min(100%, 330px);
      justify-self: end;
    }

    .tests-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 14px;
    }

    .test-card {
      display: flex;
      flex-direction: column;
      width: 100%;
      min-height: 230px;
      padding: 18px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background: var(--panel);
      color: var(--ink);
      text-decoration: none;
      text-align: left;
      box-shadow: 7px 7px 0 var(--ink);
      transform: rotate(-.4deg);
      transition: transform .16s ease, box-shadow .16s ease;
    }

    .test-card:nth-child(2n) {
      transform: rotate(.45deg);
    }

    .test-card:nth-child(3n) {
      transform: rotate(-.2deg);
    }

    .test-card:hover {
      transform: translateY(-4px) rotate(0deg);
      box-shadow: 10px 10px 0 var(--ink);
    }

    .test-card[data-accent="peach"] {
      background: #fff0e6;
      border-top: 10px solid var(--peach);
    }

    .test-card[data-accent="mint"] {
      background: #eafff6;
      border-top: 10px solid var(--mint);
    }

    .test-card[data-accent="blue"] {
      background: #edf3ff;
      border-top: 10px solid var(--blue);
    }

    .test-card[data-accent="rose"] {
      background: #fff0f7;
      border-top: 10px solid var(--rose);
    }

    .test-card[data-accent="lemon"] {
      background: #fff8c9;
      border-top: 10px solid var(--lemon);
    }

    .test-card h3 {
      margin: 10px 0 8px;
      font-size: 22px;
      line-height: 1.15;
    }

    .test-card p {
      margin: 0;
      color: var(--muted);
      line-height: 1.45;
    }

    .tag-row {
      display: flex;
      gap: 7px;
      flex-wrap: wrap;
      min-height: 28px;
    }

    .tag {
      display: inline-flex;
      align-items: center;
      min-height: 26px;
      padding: 4px 8px;
      border-radius: 999px;
      color: #343744;
      border: 2px solid var(--ink);
      background: white;
      font-size: 12px;
      font-weight: 850;
    }

    .test-card .primary-btn {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      align-self: start;
      margin-top: auto;
      box-shadow: 4px 4px 0 var(--ink);
    }

    .generators {
      margin-top: 48px;
    }

    .generator-layout {
      display: grid;
      grid-template-columns: minmax(0, 1.45fr) minmax(320px, .9fr);
      gap: 16px;
      align-items: start;
    }

    .generator-grid {
      display: grid;
      grid-template-columns: repeat(3, minmax(0, 1fr));
      gap: 14px;
    }

    .generator-card {
      display: flex;
      flex-direction: column;
      width: 100%;
      min-height: 205px;
      padding: 16px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background: white;
      color: var(--ink);
      text-decoration: none;
      text-align: left;
      box-shadow: 6px 6px 0 var(--ink);
      transition: transform .16s ease, box-shadow .16s ease;
    }

    .generator-card:hover,
    .generator-card[aria-pressed="true"] {
      transform: translateY(-3px);
      box-shadow: 9px 9px 0 var(--ink);
    }

    .generator-card[data-accent="peach"] {
      background: #fff0e6;
      border-top: 10px solid var(--peach);
    }

    .generator-card[data-accent="mint"] {
      background: #eafff6;
      border-top: 10px solid var(--mint);
    }

    .generator-card[data-accent="rose"] {
      background: #fff0f7;
      border-top: 10px solid var(--rose);
    }

    .generator-card[data-accent="violet"] {
      background: #f5edff;
      border-top: 10px solid var(--violet);
    }

    .generator-card h3 {
      margin: 10px 0 8px;
      font-size: 21px;
      line-height: 1.12;
    }

    .generator-card p {
      margin: 0 0 14px;
      color: var(--muted);
      line-height: 1.4;
    }

    .generator-card .tiny-btn {
      align-self: flex-start;
      margin-top: auto;
    }

    .generator-panel {
      padding: 18px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background:
        linear-gradient(90deg, rgba(31, 207, 143, .14) 0 16px, transparent 16px 32px),
        white;
      box-shadow: 8px 8px 0 var(--ink);
    }

    .generator-panel h3 {
      margin: 10px 0 8px;
      font-size: clamp(28px, 4vw, 38px);
      line-height: 1.04;
    }

    .generator-panel > p {
      margin: 0;
      color: var(--muted);
      line-height: 1.45;
    }

    .generator-form {
      display: grid;
      gap: 12px;
      margin-top: 18px;
    }

    .generator-form label {
      display: grid;
      gap: 7px;
      color: var(--muted);
      font-size: 13px;
      font-weight: 900;
    }

    .generator-form input {
      width: 100%;
      min-height: 48px;
      padding: 12px 14px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      background: white;
      color: var(--ink);
      outline: 0;
      font-weight: 750;
      box-shadow: 4px 4px 0 var(--ink);
    }

    .generator-form .primary-btn {
      justify-self: start;
    }

    .generator-result {
      margin-top: 18px;
      padding: 16px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background: #fff8c9;
      box-shadow: 6px 6px 0 var(--ink);
    }

    .generator-result[hidden] {
      display: none;
    }

    .generator-result h4 {
      margin: 0 0 8px;
      font-size: 25px;
      line-height: 1.08;
    }

    .generator-result p {
      margin: 0 0 14px;
      color: #343744;
      line-height: 1.5;
    }

    .seo-page,
    .seo-content {
      margin-top: 28px;
      padding: 22px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background: white;
      box-shadow: 8px 8px 0 var(--ink);
    }

    .seo-page h1 {
      margin: 12px 0;
      max-width: 920px;
      font-size: clamp(38px, 6vw, 70px);
      line-height: .98;
      text-shadow: 3px 3px 0 var(--lemon);
    }

    .seo-page p,
    .seo-content p,
    .seo-content li {
      color: var(--muted);
      font-size: 18px;
      line-height: 1.5;
    }

    .seo-page .primary-btn {
      display: inline-flex;
      margin-top: 20px;
      text-decoration: none;
    }

    .seo-content h2 {
      margin: 0 0 12px;
      font-size: 30px;
    }

    .generator-preview {
      display: block;
      width: min(100%, 340px);
      margin-top: 18px;
      box-shadow: 7px 7px 0 var(--ink);
    }

    .lab {
      display: grid;
      grid-template-columns: minmax(0, 1fr) 390px;
      gap: 18px;
      margin-top: 36px;
      padding: 22px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background:
        linear-gradient(90deg, rgba(255, 207, 29, .26) 0 16px, transparent 16px 32px),
        white;
      box-shadow: 10px 10px 0 var(--ink);
    }

    .lab[hidden] {
      display: none;
    }

    .quiz-panel {
      min-width: 0;
    }

    .quiz-kicker {
      display: inline-flex;
      width: fit-content;
      padding: 6px 10px;
      border: 2px solid var(--ink);
      border-radius: 999px;
      color: var(--ink);
      background: var(--mint);
      font-size: 13px;
      font-weight: 900;
      text-transform: uppercase;
    }

    .quiz-title {
      margin: 8px 0 16px;
      font-size: clamp(30px, 4vw, 46px);
      line-height: 1.02;
    }

    .name-row {
      display: grid;
      grid-template-columns: minmax(0, 1fr) auto;
      gap: 10px;
      margin: 18px 0;
    }

    .name-row input {
      width: 100%;
      min-height: 48px;
      padding: 12px 14px;
      border: 2px solid var(--ink);
      border-radius: var(--radius);
      background: white;
      color: var(--ink);
      outline: 0;
      font-weight: 750;
      box-shadow: 4px 4px 0 var(--ink);
    }

    .progress {
      overflow: hidden;
      height: 12px;
      margin: 8px 0 18px;
      border: 1px solid rgba(22, 23, 29, .18);
      border-radius: 999px;
      background: #eef0f6;
    }

    .progress span {
      display: block;
      width: 0%;
      height: 100%;
      border-radius: 999px;
      background: linear-gradient(90deg, var(--peach), var(--mint), var(--violet));
      transition: width .25s ease;
    }

    .question {
      margin: 0 0 14px;
      font-size: 24px;
      line-height: 1.25;
    }

    .answers {
      display: grid;
      gap: 10px;
    }

    .answer-btn {
      display: grid;
      grid-template-columns: 28px minmax(0, 1fr);
      gap: 10px;
      align-items: center;
      width: 100%;
      padding: 12px;
      border: 2px solid var(--ink);
      color: var(--ink);
      background: white;
      text-align: left;
      box-shadow: 4px 4px 0 rgba(23, 17, 31, .18);
    }

    .answer-btn span:first-child {
      display: grid;
      place-items: center;
      width: 28px;
      height: 28px;
      border-radius: 50%;
      border: 2px solid var(--ink);
      background: var(--lemon);
      font-weight: 950;
    }

    .answer-btn[aria-pressed="true"] {
      border-color: var(--ink);
      background: #d9fff1;
      box-shadow: 6px 6px 0 var(--ink);
    }

    .answer-btn:disabled {
      cursor: default;
      opacity: 1;
    }

    .quiz-nav {
      display: flex;
      justify-content: flex-start;
      gap: 10px;
      margin-top: 18px;
    }

    .result-panel {
      display: grid;
      gap: 12px;
    }

    .result-panel[hidden] {
      display: none;
    }

    .result-copy {
      padding: 16px;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background: #fff8c9;
      box-shadow: 6px 6px 0 var(--ink);
    }

    .result-copy h3 {
      margin: 0 0 8px;
      font-size: 28px;
      line-height: 1.08;
    }

    .result-copy p {
      margin: 0;
      color: #343744;
      line-height: 1.5;
    }

    .result-actions {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
    }

    .share-card-wrap {
      position: sticky;
      top: 18px;
      align-self: start;
    }

    .share-card {
      width: 100%;
      aspect-ratio: 4 / 5;
      border: 3px solid var(--ink);
      border-radius: var(--radius);
      background: #fff;
      box-shadow: 10px 10px 0 var(--ink);
    }

    .share-hint {
      margin: 12px 0 0;
      color: var(--muted);
      font-size: 13px;
      line-height: 1.4;
    }

    .history {
      display: flex;
      gap: 8px;
      flex-wrap: wrap;
      margin-top: 18px;
      min-height: 38px;
    }

    .history button {
      max-width: 220px;
      overflow: hidden;
      text-overflow: ellipsis;
      white-space: nowrap;
    }

    .toast {
      position: fixed;
      left: 50%;
      bottom: 20px;
      z-index: 20;
      transform: translateX(-50%) translateY(20px);
      opacity: 0;
      pointer-events: none;
      padding: 10px 14px;
      border-radius: var(--radius);
      color: white;
      background: var(--ink);
      box-shadow: var(--shadow);
      transition: opacity .2s ease, transform .2s ease;
    }

    .toast.show {
      opacity: 1;
      transform: translateX(-50%) translateY(0);
    }

    @media (max-width: 940px) {
      .hero,
      .lab,
      .daily,
      .generator-layout {
        grid-template-columns: 1fr;
      }

      .hero {
        min-height: auto;
      }

      .sample-card,
      .hero-art {
        max-width: 460px;
      }

      .tests-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }

      .generator-panel {
        order: -1;
      }

      .generator-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
      }

      .share-card-wrap {
        position: static;
        max-width: 420px;
      }

      .daily-card-wrap {
        justify-self: start;
        max-width: 420px;
      }
    }

    @media (max-width: 640px) {
      .shell {
        width: min(100% - 22px, 1180px);
        padding-top: 12px;
      }

      .topbar,
      .section-head,
      .quiz-nav {
        align-items: stretch;
        flex-direction: column;
      }

      .top-actions,
      .hero-actions,
      .result-actions {
        width: 100%;
      }

      .top-actions > *,
      .hero-actions > *,
      .result-actions > * {
        flex: 1 1 auto;
      }

      .stat-strip,
      .tests-grid,
      .generator-grid,
      .name-row {
        grid-template-columns: 1fr;
      }

      .lab {
        padding: 14px;
      }

      .hero h1 {
        font-size: 42px;
      }

      .hero-art {
        min-height: 360px;
      }

      .hero-icon {
        width: min(78%, 310px);
      }

      .burst {
        width: 56px;
        height: 56px;
        font-size: 40px;
      }

      .hero-sticker {
        max-width: 180px;
        font-size: 13px;
      }

      .test-card {
        min-height: 210px;
      }
    }
