@font-face { font-family: "Fraunces"; src: url("/assets/fonts/fraunces-italic.woff2") format("woff2"); font-style: italic; font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Fraunces"; src: url("/assets/fonts/fraunces.woff2") format("woff2"); font-style: normal; font-weight: 100 900; font-display: swap; }

  :root {
    --bg: #f5f3ff; --text: #1b1633; --muted: #6b6788; --line: rgba(60, 40, 120, .14);
    --glass: rgba(255, 255, 255, .72); --glass-strong: rgba(255, 255, 255, .92);
    --field: rgba(255, 255, 255, .8);
    --a1: #6d5efc; --a2: #e45bd6; --a3: #19c2a8; --grad: linear-gradient(120deg, var(--a1), var(--a2) 55%, #ff8a5c);
    --warn: #8a5a00; --warn-bg: rgba(255, 196, 80, .22); --err: #c02626;
    --shadow: 0 10px 40px -12px rgba(80, 50, 200, .28);
    --blob1: rgba(109, 94, 252, .28); --blob2: rgba(228, 91, 214, .22); --blob3: rgba(25, 194, 168, .20);
  }
  @media (prefers-color-scheme: dark) {
    :root {
      --bg: #0b0a14; --text: #f1eefc; --muted: #9a95bb; --line: rgba(255, 255, 255, .10);
      --glass: rgba(255, 255, 255, .055); --glass-strong: rgba(255, 255, 255, .09);
      --field: rgba(0, 0, 0, .28);
      --warn: #ffd98a; --warn-bg: rgba(255, 196, 80, .12); --err: #ff8f8f;
      --shadow: 0 20px 60px -20px rgba(0, 0, 0, .7);
      --blob1: rgba(109, 94, 252, .38); --blob2: rgba(228, 91, 214, .26); --blob3: rgba(25, 194, 168, .22);
    }
  }
  * { box-sizing: border-box; }
  html { scroll-behavior: smooth; }
  body {
    margin: 0; background: var(--bg); color: var(--text); min-height: 100vh; overflow-x: hidden;
    font: 16px/1.55 ui-rounded, "SF Pro Rounded", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
  }
  /* animated aurora background */
  .aurora { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
  .aurora i { position: absolute; border-radius: 50%; filter: blur(90px); will-change: transform; }
  .aurora i:nth-child(1) { width: 46vmax; height: 46vmax; background: var(--blob1); top: -14vmax; left: -10vmax; animation: drift1 22s ease-in-out infinite alternate; }
  .aurora i:nth-child(2) { width: 38vmax; height: 38vmax; background: var(--blob2); top: 10vmax; right: -12vmax; animation: drift2 26s ease-in-out infinite alternate; }
  .aurora i:nth-child(3) { width: 34vmax; height: 34vmax; background: var(--blob3); bottom: -14vmax; left: 18vmax; animation: drift3 30s ease-in-out infinite alternate; }
  @keyframes drift1 { to { transform: translate(14vmax, 10vmax) scale(1.15); } }
  @keyframes drift2 { to { transform: translate(-12vmax, 8vmax) scale(.9); } }
  @keyframes drift3 { to { transform: translate(10vmax, -8vmax) scale(1.2); } }

  .wrap { max-width: 820px; margin: 0 auto; padding: 40px 16px 72px; }

  /* glass cards */
  .card {
    background: var(--glass); border: 1px solid var(--line); border-radius: 22px; padding: 24px;
    margin-bottom: 18px; backdrop-filter: blur(22px) saturate(1.3); -webkit-backdrop-filter: blur(22px) saturate(1.3);
    box-shadow: var(--shadow); animation: rise .6s cubic-bezier(.2, .8, .2, 1) both;
  }
  .card:nth-of-type(2) { animation-delay: .08s; } .card:nth-of-type(3) { animation-delay: .16s; }
  @keyframes rise { from { opacity: 0; transform: translateY(16px); } }
  .card h2 { font-size: 1.1rem; margin: 0 0 16px; display: flex; align-items: center; gap: 12px; letter-spacing: -.01em; }
  .num {
    display: inline-grid; place-items: center; width: 30px; height: 30px; border-radius: 10px; background: var(--grad);
    color: #fff; font-size: .9rem; font-weight: 700; box-shadow: 0 6px 16px -6px var(--a1);
  }

  textarea, input[type=text], select {
    width: 100%; font: inherit; color: var(--text); background: var(--field);
    border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; outline: none; transition: border-color .15s, box-shadow .15s;
  }
  textarea:focus, input[type=text]:focus, select:focus { border-color: var(--a1); box-shadow: 0 0 0 4px color-mix(in srgb, var(--a1) 20%, transparent); }
  select option { color: #111; }
  textarea { min-height: 120px; resize: vertical; font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .85rem; margin-top: 14px; }
  label.field { display: block; font-size: .8rem; color: var(--muted); margin-bottom: 6px; letter-spacing: .02em; text-transform: uppercase; }
  .grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 16px; }
  .checks { display: grid; gap: 8px; margin-top: 18px; }
  .checks label { display: flex; gap: 10px; align-items: flex-start; font-size: .93rem; cursor: pointer; }
  .checks input { margin-top: 5px; accent-color: var(--a1); width: 16px; height: 16px; }
  .hidden { display: none !important; }

  button.primary {
    position: relative; overflow: hidden; background: var(--grad); background-size: 200% 200%; color: #fff; border: 0; border-radius: 16px;
    padding: 16px 22px; font: inherit; font-size: 1.05rem; font-weight: 700; cursor: pointer; width: 100%;
    box-shadow: 0 14px 34px -12px var(--a1); transition: transform .15s, box-shadow .15s, filter .15s; letter-spacing: .01em;
  }
  button.primary:not(:disabled):hover { transform: translateY(-2px); box-shadow: 0 20px 40px -12px var(--a2); }
  button.primary:not(:disabled):active { transform: translateY(0) scale(.99); }
  button.primary:not(:disabled)::after {
    content: ""; position: absolute; top: 0; left: -60%; width: 40%; height: 100%;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .35), transparent); transform: skewX(-20deg); animation: sweep 3.2s ease-in-out infinite;
  }
  @keyframes sweep { 60%, 100% { left: 130%; } }
  button.primary:disabled { filter: grayscale(.8); opacity: .4; cursor: not-allowed; box-shadow: none; }
  button.ghost {
    background: var(--field); color: var(--text); border: 1px solid var(--line); border-radius: 10px; padding: 7px 14px; font: inherit; font-size: .86rem; cursor: pointer;
  }
  button.ghost:hover { border-color: var(--a1); }
  details summary:hover { color: var(--text); }
  pre.prompt {
    white-space: pre-wrap; background: var(--field); border: 1px solid var(--line); border-radius: 12px; padding: 14px; font-size: .84rem; margin: 12px 0; line-height: 1.5;
  }
  .status { margin: 12px 0 0; font-size: .95rem; text-align: center; min-height: 1.4em; }
  .tip { color: var(--muted); font-size: .84rem; margin: 12px 0 0; text-align: center; }
  .foot { color: var(--muted); font-size: .84rem; margin-top: 30px; text-align: center; }
  .confetti { position: fixed; top: 0; left: 0; width: 9px; height: 14px; border-radius: 2px; pointer-events: none; z-index: 50; }
  @media (max-width: 520px) { .card { padding: 18px; border-radius: 18px; } .nav { width: 36px; height: 36px; } .face { font-size: 1.05rem; } }
  @media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } }

/* ---------- Zlata's Toolkit: brand, hub, tool cards ---------- */
a { color: inherit; }
.topbar { max-width: 820px; margin: 0 auto; padding: 20px 16px 0; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { font-family: "Fraunces", Georgia, serif; font-style: italic; font-weight: 700; font-size: 1.4rem; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; letter-spacing: -.01em; }
.brand .spark { color: var(--a2); animation: twinkle 3.4s ease-in-out infinite; }
.brand em { background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; padding-right: .1em; }
.back { font-size: .9rem; color: var(--muted); text-decoration: none; padding: 7px 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--glass); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); transition: color .15s, border-color .15s; }
.back:hover { color: var(--text); border-color: var(--a1); }

.mast { text-align: center; position: relative; padding: 36px 0 6px; }
.mast .stars { position: absolute; inset: 0; pointer-events: none; }
.mast .stars span { position: absolute; color: var(--a2); font-size: 1.1rem; opacity: .0; animation: twinkle 4s ease-in-out infinite; }
.mast .stars span:nth-child(1) { top: 6%; left: 8%; animation-delay: .2s; font-size: 1.5rem; }
.mast .stars span:nth-child(2) { top: 22%; right: 7%; animation-delay: 1.1s; color: var(--a3); }
.mast .stars span:nth-child(3) { top: 58%; left: 2%; animation-delay: 2s; color: var(--a1); }
.mast .stars span:nth-child(4) { top: 64%; right: 3%; animation-delay: 2.7s; font-size: 1.6rem; }
.mast .stars span:nth-child(5) { top: 0%; left: 52%; animation-delay: 3.2s; font-size: .9rem; }
@keyframes twinkle { 0%, 100% { opacity: .15; transform: scale(.7) rotate(0); } 50% { opacity: 1; transform: scale(1.15) rotate(18deg); } }
.mast h1.title {
  font-family: "Fraunces", Georgia, "Times New Roman", serif; font-style: italic; font-weight: 800;
  font-size: clamp(3.8rem, 18vw, 8rem); line-height: .98; letter-spacing: -.035em; margin: 0; padding: 0 .08em .08em;
  background: linear-gradient(100deg, #8b7bff 0%, #ff6ad5 35%, #ffb36b 60%, #8b7bff 100%); background-size: 250% 100%;
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent;
  animation: flow 10s linear infinite; filter: drop-shadow(0 12px 44px rgba(228, 91, 214, .38));
}
@keyframes flow { to { background-position: -250% 0; } }
.mast .kit {
  display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 4px;
  font-family: "Fraunces", Georgia, serif; font-weight: 500; text-transform: uppercase; letter-spacing: .55em; color: var(--muted);
  font-size: clamp(.85rem, 3.6vw, 1.35rem);
}
.mast .kit span { margin-right: -.55em; }
.mast .kit::before, .mast .kit::after { content: ""; height: 1px; width: clamp(24px, 10vw, 96px); background: linear-gradient(90deg, transparent, var(--a2)); }
.mast .kit::after { transform: scaleX(-1); }
.mast .tag { color: var(--muted); max-width: 460px; margin: 22px auto 0; font-size: 1.05rem; }

.tools { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 18px; margin-top: 40px; }
.tool {
  position: relative; display: flex; flex-direction: column; gap: 10px; padding: 22px; border-radius: 22px; text-decoration: none; color: inherit;
  background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(22px) saturate(1.3); -webkit-backdrop-filter: blur(22px) saturate(1.3);
  box-shadow: var(--shadow); transition: transform .25s cubic-bezier(.2, .8, .2, 1), border-color .25s, box-shadow .25s;
  animation: rise .6s cubic-bezier(.2, .8, .2, 1) both; animation-delay: calc(var(--i, 0) * .09s + .1s);
}
.tool:hover, .tool:focus-visible { transform: translateY(-6px) rotate(-.4deg); border-color: var(--a2); box-shadow: 0 26px 50px -20px var(--a2); outline: none; }
.tool .ico { width: 56px; height: 56px; border-radius: 17px; display: grid; place-items: center; font-size: 1.9rem; background: var(--grad); box-shadow: 0 10px 24px -8px var(--a1); }
.tool h3 { margin: 8px 0 0; font-size: 1.2rem; letter-spacing: -.01em; }
.tool p { margin: 0; color: var(--muted); font-size: .94rem; flex: 1; }
.tool .fmt { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: .78rem; color: var(--muted); display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.tool .fmt b { font-weight: 600; padding: 2px 8px; border-radius: 6px; background: var(--field); border: 1px solid var(--line); }
.tool .go { position: absolute; top: 24px; right: 22px; font-size: 1.3rem; opacity: .35; transition: transform .25s, opacity .25s; }
.tool:hover .go { transform: translateX(5px); opacity: 1; }
.tool.soon { border-style: dashed; background: transparent; box-shadow: none; backdrop-filter: none; -webkit-backdrop-filter: none; justify-content: center; align-items: center; text-align: center; color: var(--muted); min-height: 200px; cursor: default; }
.tool.soon:hover { transform: none; box-shadow: none; border-color: var(--line); }
.tool.soon .ico { background: transparent; box-shadow: none; border: 1px dashed var(--line); color: var(--a2); }
.tool.soon h3 { color: var(--text); }

/* hero */
  .hero { text-align: center; margin-bottom: 28px; position: relative; }
  .pill {
    display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px;
    background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    font-size: .82rem; color: var(--muted); margin-bottom: 18px;
  }
  .pill b { width: 8px; height: 8px; border-radius: 50%; background: var(--a3); box-shadow: 0 0 0 0 var(--a3); animation: ping 2.2s infinite; }
  @keyframes ping { 70% { box-shadow: 0 0 0 9px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }
  h1 {
    font-size: clamp(2.4rem, 8vw, 4rem); line-height: 1.05; margin: 0 0 14px; letter-spacing: -0.035em; font-weight: 800;
  }
  h1 span {
    background: var(--grad); background-size: 200% 200%; -webkit-background-clip: text; background-clip: text;
    -webkit-text-fill-color: transparent; color: transparent; animation: shine 8s ease-in-out infinite alternate;
  }
  @keyframes shine { to { background-position: 100% 50%; } }
  .sub { color: var(--muted); margin: 0 auto; max-width: 520px; font-size: 1.05rem; }

  
.brand, .back { white-space: nowrap; }
.hero h1 { font-size: clamp(2.4rem, 8vw, 4rem); }
@media (max-width: 430px) {
  .brand { font-size: 1.1rem; gap: 6px; }
  .back { padding: 6px 11px; font-size: .82rem; }
  .hide-sm { display: none; }
  .topbar { padding-top: 14px; }
}
