@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700;800&family=Space+Mono:wght@400;700&display=swap');

:root {
  color-scheme: dark;
  --bg: #080a16;
  --text: #f4f3ff;
  --muted: #9699b4;
  --line: #b0b5f116;
  --violet: #a38aff;
  --cyan: #84d8ff;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 24px; overflow-x: clip; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: 'DM Sans', sans-serif; min-height: 100svh; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button:focus-visible, a:focus-visible { outline: 2px solid #c5b9ff; outline-offset: 5px; }
[hidden] { display: none !important; }

.scene { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: -1; background: #080a16; }
.aurora { position: absolute; border-radius: 50%; filter: blur(80px); opacity: .55; }
.aurora-violet { width: 630px; height: 530px; top: -200px; left: 38%; background: #6134b84a; }
.aurora-blue { width: 500px; height: 600px; top: 190px; right: -300px; background: #2373a336; }
.starfield { position: absolute; inset: 0; opacity: .55; background-image: radial-gradient(1px 1px at 12% 23%, #c0b4ff, transparent), radial-gradient(1px 1px at 27% 48%, #8fc4ec, transparent), radial-gradient(2px 2px at 76% 16%, #d5ccff, transparent), radial-gradient(1px 1px at 91% 64%, #9b8cde, transparent), radial-gradient(1px 1px at 43% 9%, #d5ccff, transparent), radial-gradient(1px 1px at 3% 68%, #d5ccff, transparent); }
.grid-floor { position: absolute; width: 120%; left: -10%; height: 600px; top: 590px; background-image: linear-gradient(#a5a2ef07 1px, transparent 1px), linear-gradient(90deg, #a5a2ef07 1px, transparent 1px); background-size: 54px 54px; transform: perspective(400px) rotateX(56deg); transform-origin: top; mask-image: linear-gradient(transparent, #000 30%, transparent 80%); }
.shell { max-width: 1280px; margin: 0 auto; padding: 0 60px; }
.site-header { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 30px 0; border-bottom: 1px solid var(--line); }
.brand { display: inline-flex; align-items: center; gap: 12px; font-size: 20px; font-weight: 800; letter-spacing: 2px; }
.brand-mark { display: grid; place-items: center; height: 44px; width: 44px; background: linear-gradient(145deg, #b89dff, #7360f1 60%, #75b9f1); border: 1px solid #c4b6ff88; box-shadow: inset 0 1px 0 #fff5, 0 4px 28px #8d70ff26; border-radius: 14px; font-size: 14px; letter-spacing: -1px; color: white; transform: rotate(-7deg); }
.brand-sub { display: block; font-size: 8px; font-weight: 500; letter-spacing: 2px; color: #9b9bbd; margin-top: 3px; }
.help-link { color: #aaa8c6; font-size: 12px; padding: 9px 0; }
.help-link span { margin-left: 9px; color: #c4b7ff; }
.help-link:hover { color: white; }

.hero { display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; gap: 72px; padding: 68px 0 70px; }
.eyebrow { display: flex; align-items: center; gap: 9px; color: #b3a4f5; font-size: 10px; font-weight: 600; letter-spacing: 2px; margin-bottom: 25px; }
.eyebrow span { width: 20px; height: 1px; background: #b99aff; box-shadow: 0 0 10px #aa7cff80; }
h1 { font-size: clamp(40px, 4.2vw, 59px); font-weight: 600; line-height: 1.16; letter-spacing: -2.8px; margin: 0 0 25px; }
h1 span { display: inline-block; color: #c2adff; background: linear-gradient(105deg, #d1c1ff, #aa93f2 50%, #8dd5f5); background-clip: text; -webkit-text-fill-color: transparent; }
.lead { max-width: 370px; color: var(--muted); font-size: 15px; line-height: 1.9; margin: 0; }
.benefits { display: flex; gap: 0; margin: 34px 0 29px; padding: 22px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.benefits > div { flex: 1; padding: 0 17px; border-right: 1px solid var(--line); }
.benefits > div:first-child { padding-left: 0; }
.benefits > div:last-child { border: 0; padding-right: 0; }
.benefits strong { display: flex; align-items: baseline; gap: 6px; font-size: 26px; font-weight: 500; letter-spacing: -1px; }
.benefits strong span { font-size: 11px; color: #c3bfd8; letter-spacing: 0; }
.benefits small { display: block; font-size: 10px; color: #797f9f; margin-top: 5px; }
.intro-link { display: inline-flex; gap: 35px; align-items: center; color: #c8c1e5; font-size: 12px; }
.intro-link span { color: #a79be0; border: 1px solid #a79be030; width: 27px; height: 27px; display: grid; place-items: center; border-radius: 50%; }

.card-wrap { position: relative; min-width: 0; }
.card-glow { position: absolute; inset: 10% -10%; background: radial-gradient(ellipse, #6d42d533, #418bd41c 38%, transparent 70%); filter: blur(35px); pointer-events: none; }
.key-card { position: relative; padding: 26px 29px 23px; border: 1px solid #b7a6ff35; border-radius: 27px; background: radial-gradient(ellipse at 60% 0, #55408525, transparent 60%), linear-gradient(145deg, #1b1c31e6, #111524ed); box-shadow: 0 30px 90px #0005, 0 0 55px #7754d00c, inset 0 1px 0 #e4d9ff1a; backdrop-filter: blur(20px); }
.key-card::before { content: ''; position: absolute; height: 1px; top: -1px; left: 19%; right: 19%; background: linear-gradient(90deg, transparent, #c4a8ff, #b6d9ff, transparent); box-shadow: 0 0 12px #bf9dff70; }
.card-topline { display: flex; align-items: center; justify-content: space-between; gap: 15px; }
.card-brand { font-size: 8px; font-weight: 500; letter-spacing: 2.4px; color: #8987ae; }
.status { display: inline-flex; align-items: center; gap: 6px; font-size: 9px; color: #b8d8cd; background: #75d5aa08; border: 1px solid #85d7b318; border-radius: 20px; padding: 6px 9px; }
#status-dot { width: 4px; height: 4px; border-radius: 50%; background: #85e5bf; box-shadow: 0 0 8px #85e5bf60; }
.key-visual { width: 160px; height: 130px; margin: 16px auto 4px; position: relative; background: radial-gradient(ellipse, #9875ff22, transparent 68%); }
.orbit { position: absolute; border: 1px solid #b598ff48; border-radius: 50%; width: 144px; height: 66px; left: 8px; top: 34px; box-shadow: inset 0 0 15px #9d6cfa08, 0 0 15px #9d6cfa08; }
.orbit-one { transform: rotate(-28deg); border-bottom-color: #7199e977; }
.orbit-two { transform: rotate(32deg); border-color: #9ac0fc27; }
.orbit-one::after { content: ''; position: absolute; right: 13px; top: 3px; height: 5px; width: 5px; border-radius: 50%; background: #cdbaff; box-shadow: 0 0 10px #b99aff; }
.key-object { position: absolute; width: 46px; height: 98px; left: 57px; top: 7px; transform: rotate(39deg); filter: drop-shadow(0 4px 12px #a08bfa30); animation: key-float 7s ease-in-out infinite; }
.key-head { position: absolute; width: 42px; height: 42px; border-radius: 50%; background: linear-gradient(130deg, #eef5ff, #b9b3ee 35%, #7776c3 60%, #d6e7ff); box-shadow: inset -3px -2px 3px #4e4679aa, inset 3px 2px 4px #ffffffaa; }
.key-head::after { content: ''; position: absolute; inset: 11px; border-radius: 50%; background: #272640; box-shadow: inset 2px 2px 3px #020414b0, 1px 1px 1px #fff9; }
.key-stem { position: absolute; top: 35px; left: 14px; width: 14px; height: 56px; border-radius: 0 0 4px 4px; background: linear-gradient(90deg, #a8addb, #eef6ff 40%, #8582bd 90%); box-shadow: inset -2px 0 2px #595189aa; }
.key-tooth { position: absolute; left: 25px; height: 11px; width: 17px; border-radius: 0 3px 3px 0; background: linear-gradient(180deg, #d8defc, #8484b8); box-shadow: inset 0 -2px 1px #55547d77; }
.tooth-one { top: 66px; }
.tooth-two { top: 82px; width: 13px; }
.key-shadow { position: absolute; width: 55px; height: 8px; background: #9578ff3a; filter: blur(6px); left: 52px; bottom: 7px; border-radius: 50%; }
.spark { position: absolute; color: #b8a4fa; }
.spark-one { left: 14px; top: 18px; font-size: 11px; }
.spark-two { right: 2px; bottom: 18px; font-size: 16px; color: #8bbfe6; }
.key-card h2 { text-align: center; margin: 12px 0 12px; font-size: 27px; line-height: 1.25; font-weight: 600; letter-spacing: -.9px; }
.description { text-align: center; font-size: 12px; line-height: 1.8; color: #9c9fbb; margin: 0 auto 22px; max-width: 310px; min-height: 43px; }
.primary { position: relative; overflow: hidden; width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; border: 1px solid #ccb9ff70; padding: 18px 20px; border-radius: 13px; background: linear-gradient(105deg, #8a66ec, #917af0 48%, #719bdd); box-shadow: inset 0 1px 0 #ffffff30, 0 6px 26px #7d55e52b; color: white; font-size: 14px; font-weight: 700; cursor: pointer; transition: box-shadow .2s, transform .2s; }
.primary::before { content: ''; position: absolute; width: 45%; height: 200%; top: -50%; left: -80%; transform: rotate(22deg); background: linear-gradient(90deg, transparent, #ffffff18, transparent); animation: button-shine 9s ease-in-out infinite; pointer-events: none; }
.primary:hover { transform: translateY(-2px); box-shadow: inset 0 1px 0 #ffffff40, 0 10px 35px #7d55e54a; }
.primary span { position: relative; }
#button-arrow { display: grid; place-items: center; width: 24px; height: 24px; border: 1px solid #fff3; border-radius: 7px; font-size: 16px; }
.primary:disabled { background: #a69fda12; border-color: #a69fda20; color: #9290ad; box-shadow: none; cursor: default; transform: none; }
.primary:disabled::before { display: none; }
.feedback { font-size: 11px; line-height: 1.8; color: #ffbdc7; margin: 13px 0; overflow-wrap: anywhere; }
.feedback:empty { margin: 0; }
.card-foot { display: flex; justify-content: center; align-items: center; gap: 7px; border-top: 1px solid var(--line); margin: 20px 0 0; padding-top: 17px; font-size: 9px; line-height: 1.7; color: #777d9b; text-align: center; }
.card-foot > span { color: #a797d9; font-size: 13px; }

.key-result { padding: 15px; border: 1px solid #a492e936; border-radius: 13px; background: #0b102580; margin-bottom: 18px; }
.key-result label { display: flex; align-items: center; gap: 7px; color: #b9acec; font-size: 9px; letter-spacing: 1.5px; margin-bottom: 12px; }
.result-dot { width: 4px; height: 4px; background: #8be2c4; border-radius: 50%; }
.key-line { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.key-line input { flex: 1; min-width: 0; width: 100%; font: 11px 'Space Mono', monospace; color: #e3d9ff; border: 0; outline: none; background: transparent; padding: 8px 0; }
.key-line button { background: #a28ae91c; border: 1px solid #c1adff30; border-radius: 7px; color: #d9caff; padding: 8px 10px; font-size: 10px; cursor: pointer; }
.key-result p { font-size: 10px; line-height: 1.8; color: var(--muted); margin: 10px 0 0; }
.countdown { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 0 22px; }
.countdown span { font-size: 11px; color: #c1bdd6; }
.countdown small { display: block; font-size: 9px; color: #757d9d; margin-top: 6px; }
.countdown strong { font: 400 25px 'Space Mono', monospace; color: #d4c7ff; letter-spacing: -1px; }

.guide { padding: 30px 0 55px; border-top: 1px solid var(--line); }
.guide-heading { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
.guide-heading h2 { font-size: 18px; font-weight: 500; margin: 0; letter-spacing: -.4px; }
.guide-heading > p { color: #7e829f; font-size: 11px; margin: 0; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; list-style: none; padding: 0; margin: 0; }
.steps li { display: flex; align-items: flex-start; gap: 13px; padding: 21px 19px; border: 1px solid #a8a3e014; border-radius: 14px; background: linear-gradient(130deg, #9f8fed05, #9f8fed02); }
.step-icon { display: grid; place-items: center; height: 30px; width: 30px; flex-shrink: 0; color: #b0a1ea; background: #a48bfb0a; border: 1px solid #a48bfb17; border-radius: 9px; font-size: 15px; }
.steps h3 { font-size: 12px; font-weight: 500; margin: 3px 0 9px; color: #cbc6e1; }
.steps p { font-size: 10px; line-height: 1.9; margin: 0; color: #7f849f; }
.steps strong { color: #a9a4c4; font-weight: 500; }
footer { display: flex; align-items: center; justify-content: space-between; gap: 20px; border-top: 1px solid var(--line); padding: 24px 0; color: #5f6583; font-size: 9px; }
footer > span:first-child { font-size: 8px; letter-spacing: 1.2px; }
.footer-divider { color: #464663; padding: 0 9px; }

.history-button { width: 100%; display: flex; align-items: center; justify-content: center; gap: 8px; padding: 13px 15px; margin-top: 12px; border: 1px solid #b6a4ef29; border-radius: 11px; background: #ad99f508; color: #c9bce9; font-size: 12px; cursor: pointer; transition: background .2s; }
.history-button:hover { background: #ad99f514; }
.history-button:disabled { opacity: .5; cursor: wait; }
.history-button > span { font-size: 17px; }
#history-dialog { width: min(540px, calc(100% - 32px)); max-height: 85svh; padding: 25px; color: var(--text); background: linear-gradient(145deg, #1c1c31, #111524); border: 1px solid #b7a6ff45; border-radius: 22px; box-shadow: 0 30px 120px #0009; }
#history-dialog::backdrop { background: #050711c7; backdrop-filter: blur(8px); }
.history-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 14px; }
.history-heading h2 { font-size: 22px; font-weight: 600; letter-spacing: -.6px; margin: 0 0 9px; }
.history-heading p { font-size: 11px; color: var(--muted); line-height: 1.8; margin: 0; }
#history-close { display: grid; place-items: center; width: 32px; height: 32px; flex-shrink: 0; padding: 0; background: #c1adff08; color: #b8adcf; border: 1px solid #c1adff20; border-radius: 9px; font-size: 24px; line-height: 1; cursor: pointer; }
.history-message { color: #b4a9cd; font-size: 12px; line-height: 1.8; margin: 18px 0; }
.history-message:empty { margin: 0; }
.history-list { list-style: none; margin: 20px 0 0; padding: 0; display: grid; gap: 11px; }
.history-list:empty { margin: 0; }
.history-item { padding: 15px; border: 1px solid #b9a9ed1c; border-radius: 12px; background: #080d1d55; }
.history-item-heading { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 11px; }
.history-item time { color: #9297b0; font-size: 10px; }
.history-state { font-size: 9px; color: #beadf5; background: #a98fe811; border: 1px solid #a98fe824; border-radius: 5px; padding: 4px 6px; white-space: nowrap; }
.history-state.active { color: #86d9b6; background: #86d9b60c; border-color: #86d9b628; }
.history-state.expired, .history-state.deleted { color: #a4a7b9; background: #a4a7b908; border-color: #a4a7b91a; }
.history-state.disabled { color: #e0a0b2; background: #e0a0b20a; border-color: #e0a0b222; }
.history-key-line { display: flex; align-items: center; gap: 8px; }
.history-key { flex: 1; min-width: 0; width: 100%; padding: 7px 0; color: #ded2fb; background: transparent; border: 0; outline: none; font: 11px 'Space Mono', monospace; }
.history-key-line button { flex-shrink: 0; border: 1px solid #b9a5ed2b; border-radius: 6px; background: #b9a5ed0d; color: #cfc0ee; font-size: 10px; padding: 8px; cursor: pointer; }
.history-expiry { color: #7e839e; font-size: 10px; line-height: 1.8; margin: 9px 0 0; }
@media (max-width: 500px) { #history-dialog { padding: 21px 17px; } .history-key-line { flex-wrap: wrap; } .history-key { flex-basis: 100%; } .history-key-line button { margin-left: auto; } }

@keyframes key-float { 0%, 100% { transform: translateY(0) rotate(39deg); } 50% { transform: translateY(-6px) rotate(44deg); } }
@keyframes button-shine { 0%, 68%, 100% { left: -80%; } 88% { left: 150%; } }
@media (max-width: 1050px) {
  .shell { padding: 0 34px; }
  .hero { gap: 34px; }
  h1 { font-size: 45px; }
  .key-card { padding: 23px; }
  .benefits > div { padding: 0 10px; }
  .steps { gap: 12px; }
  .steps li { padding: 18px 15px; }
}
@media (max-width: 760px) {
  .shell { padding: 0 24px; max-width: 570px; }
  .site-header { padding: 21px 0; }
  .brand { font-size: 17px; }
  .brand-mark { width: 39px; height: 39px; border-radius: 12px; font-size: 13px; }
  .brand-sub { font-size: 6px; }
  .help-link { font-size: 10px; }
  .help-link span { margin-left: 5px; }
  .hero { grid-template-columns: 1fr; gap: 30px; padding: 38px 0 40px; }
  .eyebrow { margin-bottom: 17px; font-size: 8px; letter-spacing: 1.7px; }
  h1 { font-size: clamp(33px, 8.5vw, 43px); letter-spacing: -1.7px; margin-bottom: 17px; }
  .lead { max-width: 100%; font-size: 12px; line-height: 1.9; }
  .benefits { margin: 24px 0 0; padding: 18px 0; }
  .benefits strong { font-size: 24px; }
  .benefits strong span { font-size: 10px; }
  .benefits small { font-size: 9px; }
  .intro-link { display: none; }
  .key-card { border-radius: 24px; padding: 23px; }
  .key-card h2 { font-size: clamp(23px, 6vw, 28px); }
  .key-visual { margin-top: 18px; }
  .description { font-size: 12px; }
  .primary { padding: 17px 18px; font-size: 14px; }
  .guide { padding: 27px 0 35px; }
  .guide-heading { display: block; margin-bottom: 19px; }
  .guide-heading h2 { font-size: 17px; margin-bottom: 10px; }
  .guide-heading > p { font-size: 10px; line-height: 1.8; }
  .steps { grid-template-columns: 1fr; gap: 10px; }
  .steps li { padding: 17px; }
  .steps h3 { font-size: 12px; margin-bottom: 5px; }
  .steps p { font-size: 11px; }
  .key-line input { flex-basis: 100%; font-size: 11px; }
  .key-line button { margin-left: auto; }
  footer { flex-direction: column; align-items: flex-start; gap: 10px; padding: 22px 0; }
  .aurora-violet { width: 450px; height: 600px; left: -140px; top: -120px; opacity: .4; }
  .aurora-blue { top: 400px; right: -340px; }
  .grid-floor { top: 670px; }
}
@media (max-width: 350px) {
  .shell { padding: 0 17px; }
  .key-card { padding: 21px 18px; }
  .benefits strong { font-size: 21px; }
  .benefits small { font-size: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
