:root {
    --navy-950: #141a25;
    --navy-900: #1a2230;
    --navy-800: #252e3b;
    --navy-750: #2c3542;
    --navy-700: #333d4b;
    --purple: #9b8aec;
    --purple-dark: #7e6dd1;
    --text: #f4f4f7;
    --text-soft: #d4d6dc;
    --muted: #a7acb7;
    --line: rgba(255, 255, 255, 0.11);
    --danger: #ef8b92;
    --success: #75d59a;
    --input-bg: #111824;
    --button-ink: #111420;
    --accent-soft: rgba(155, 138, 236, .14);
    --subtle-bg: rgba(255, 255, 255, .035);
    --empty-bg: rgba(20, 26, 37, .48);
    --shadow: 0 18px 44px rgba(8, 12, 18, .16);
    --shell: min(1200px, calc(100vw - 48px));
    --header-height: 64px;
}

html[data-theme="light"] {
    --navy-950: #e3e6ec;
    --navy-900: #ffffff;
    --navy-800: #f4f6f9;
    --navy-750: #e9edf3;
    --navy-700: #dce1e9;
    --text: #1c2330;
    --text-soft: #343d4c;
    --muted: #667183;
    --line: rgba(24, 32, 46, .14);
    --input-bg: #f8f9fb;
    --button-ink: #121722;
    --accent-soft: rgba(126, 109, 209, .13);
    --subtle-bg: rgba(24, 32, 46, .045);
    --empty-bg: rgba(255, 255, 255, .55);
    --shadow: 0 18px 44px rgba(44, 54, 70, .10);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-height) + 22px); }
body { margin: 0; overflow-x: hidden; background: var(--navy-800); color: var(--text); font-family: Inter, "Segoe UI", Arial, sans-serif; font-size: 16px; line-height: 1.65; transition: background-color .22s ease, color .22s ease; }
body.menu-open { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { color: inherit; }
::selection { background: var(--purple); color: var(--navy-950); }
.shell { width: var(--shell); margin-inline: auto; }
.sr-only { position: absolute; width: 1px; height: 1px; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
.skip-link { position: fixed; z-index: 999; top: 8px; left: 8px; padding: 9px 13px; background: white; color: #111; border-radius: 0; transform: translateY(-150%); }
.skip-link:focus { transform: translateY(0); }

.site-header { position: sticky; z-index: 100; top: 0; height: var(--header-height); background: var(--navy-900); background: color-mix(in srgb, var(--navy-900) 94%, transparent); border-bottom: 1px solid var(--line); backdrop-filter: blur(12px); animation: header-in .42s ease-out both; }
.header-inner { height: 100%; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 38px; }
.brand { display: inline-flex; align-items: center; gap: 10px; width: max-content; }
.brand img { width: 38px; height: 38px; object-fit: contain; transition: transform .24s ease; }
.brand:hover img, .brand:focus-visible img { transform: rotate(-7deg) scale(1.06); }
.brand strong { font-size: 1rem; letter-spacing: -.015em; }
.site-nav { justify-self: end; display: flex; align-items: center; gap: 5px; }
.site-nav a { position: relative; padding: 8px 12px; border-radius: 0; text-decoration:none;}
.site-nav a, .footer-inner nav a { color: var(--text-soft); font-size: .92rem; font-weight: 650; transition: color .15s ease, background-color .15s ease; }
.site-nav a:hover, .site-nav a:focus-visible, .footer-inner nav a:hover, .footer-inner nav a:focus-visible { color: var(--purple); }
.site-nav a.is-active { background: var(--accent-soft); color: var(--purple); }
.site-nav a.is-active::after { right: 12px; left: 12px; }
.header-controls { display: flex; align-items: center; gap: 10px; }
.theme-toggle { display: inline-flex; align-items: center; gap: 7px; min-height: 38px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 0; background: transparent; color: var(--text-soft); cursor: pointer; font-size: .8rem; font-weight: 700; }
.theme-toggle:hover, .theme-toggle:focus-visible { border-color: var(--purple); color: var(--purple); }
.menu-toggle { display: none; }

.button { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; padding: 10px 20px; border: 1px solid transparent; border-radius: 0; cursor: pointer; font-size: .94rem; font-weight: 750; line-height: 1.2; text-align: center; transition: background-color .15s ease, border-color .15s ease, transform .15s ease; }
.button:hover { transform: translateY(-2px); }
.button:active { transform: translateY(0) scale(.985); }
.button-primary { background: var(--purple); color: var(--button-ink); }
.button-primary:hover, .button-primary:focus-visible { background: var(--purple-dark); color: #fff; }
.button-secondary { background: var(--navy-900); border-color: var(--line); color: var(--text); }
.button-secondary:hover, .button-secondary:focus-visible { background: var(--navy-700); border-color: rgba(255,255,255,.2); }
.button-light { background: #f1f2f5; color: #171b24; }
.button-light:hover, .button-light:focus-visible { background: var(--purple); }
.button-small { min-height: 38px; padding: 8px 16px; font-size: .84rem; }
.button-large { min-height: 61px; padding: 12px 22px; font-size: 1.03rem; }
.button-large small { display: block; margin-left: 9px; font-size: .74rem; font-weight: 500; opacity: .78; }
.button:disabled { cursor: not-allowed; opacity: .48; transform: none; }
.button.is-disabled { cursor: not-allowed; opacity: .56; pointer-events: none; transform: none; }

.hero { position: relative; overflow: hidden; padding: 92px 0 88px; background: var(--navy-750); border-bottom: 1px solid var(--line); isolation: isolate; }
.hero-mark { position: absolute; z-index: -1; right: -80px; top: 50%; width: 600px; height: 600px; transform: translateY(-50%); opacity: .055; animation: logo-float 7s ease-in-out infinite; }
.hero-mark img { width: 100%; height: 100%; object-fit: contain; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(330px, .68fr); gap: 100px; align-items: center; }
.hero-copy > *, .hero-actions > * { animation: hero-rise .52s cubic-bezier(.2,.72,.26,1) both; }
.hero-copy > :nth-child(1) { animation-delay: .06s; }
.hero-copy > :nth-child(2) { animation-delay: .12s; }
.hero-copy > :nth-child(3) { animation-delay: .2s; }
.hero-copy > :nth-child(4) { animation-delay: .28s; }
.hero-actions > :nth-child(1) { animation-delay: .19s; }
.hero-actions > :nth-child(2) { animation-delay: .27s; }
.hero-actions > :nth-child(3) { animation-delay: .35s; }
.hero-actions > :nth-child(4) { animation-delay: .4s; }
.overline { margin: 0 0 12px; color: var(--purple); font-size: .82rem; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
h1, h2, h3, p { overflow-wrap: anywhere; }
h1, h2 { margin: 0; line-height: 1.12; letter-spacing: -.035em; }
h1 { color: var(--purple); font-size: clamp(3rem, 5.6vw, 5rem); }
h2 { font-size: clamp(2rem, 4vw, 3.35rem); }
.hero-intro { max-width: 710px; margin: 24px 0 28px; color: var(--text-soft); font-size: clamp(1.12rem, 2vw, 1.45rem); line-height: 1.6; }
.hero-tags { display: flex; flex-wrap: wrap; gap: 10px; }
.hero-tags span { padding: 7px 11px; background: var(--subtle-bg); border: 1px solid var(--line); border-radius: 0; color: var(--text-soft); font-size: .79rem; }
.hero-actions { display: grid; gap: 14px; }
.hero-actions .button { justify-content: space-between; }
.release-line { margin: 2px 0 0; color: var(--muted); font-size: .8rem; text-align: center; }
.download-notice { margin: 0; padding: 11px 13px; background: rgba(239,139,146,.1); border: 1px solid rgba(239,139,146,.33); border-radius: 0; color: #ffc2c7; font-size: .84rem; text-align: center; }

.social-strip { padding: 25px 0; background: var(--navy-800); border-bottom: 1px solid var(--line); }
.social-links { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 14px; }
.social-link { display: grid; place-items: center; width: 50px; height: 50px; border: 1px solid color-mix(in srgb, var(--purple) 50%, var(--line)); border-radius: 0; background: var(--purple); color: #fff; box-shadow: 0 8px 22px color-mix(in srgb, var(--purple) 22%, transparent); transition: transform .2s ease, box-shadow .2s ease, background-color .2s ease; }
.social-link img { display: block; width: 24px; height: 24px; object-fit: contain; }
.social-link:hover, .social-link:focus-visible { background: var(--purple-dark); color: #fff; box-shadow: 0 12px 28px color-mix(in srgb, var(--purple) 32%, transparent); transform: translateY(-3px); }

.section { padding: 88px 0; }
.section-heading { display: flex; justify-content: space-between; align-items: end; gap: 40px; margin-bottom: 30px; }
.section-heading > div > p:last-child, .simple-heading > p:last-child { max-width: 700px; margin: 13px 0 0; color: var(--muted); }
.simple-heading { margin-bottom: 30px; }

.server-section { background: var(--navy-800); }
.add-server-panel { padding: 24px; background: var(--navy-900); border: 1px solid var(--line); border-radius: 0; box-shadow: var(--shadow); }
.add-server-form { display: grid; grid-template-columns: .85fr 1.2fr 130px auto; gap: 14px; align-items: end; }
.field { display: grid; gap: 7px; }
.field label { color: var(--text-soft); font-size: .82rem; font-weight: 700; }
.field label span { color: var(--muted); font-weight: 400; }
.field input { width: 100%; height: 46px; padding: 0 13px; border: 1px solid var(--line); border-radius: 0; outline: none; background: var(--input-bg); color: var(--text); }
.field input::placeholder { color: #6f7581; }
.field input:focus { border-color: var(--purple); box-shadow: 0 0 0 3px rgba(155,138,236,.14); }
.add-server-button { min-width: 128px; height: 46px; }
.form-message { grid-column: 1 / -1; min-height: 20px; margin: -2px 0 0; color: var(--muted); font-size: .8rem; }
.form-message.is-error { color: #ffb2b7; }
.form-message.is-success { color: #a9ecc1; }
.server-toolbar { display: flex; align-items: end; justify-content: space-between; gap: 28px; margin-top: 22px; }
.server-search { width: min(100%, 470px); }
.server-toolbar > p { margin: 0 0 10px; color: var(--muted); font-size: .86rem; white-space: nowrap; }
.server-toolbar > p strong { color: var(--text); }
.server-list { display: grid; gap: 14px; margin-top: 18px; }
.server-empty, .server-loading { display: flex; align-items: center; gap: 19px; min-height: 130px; padding: 26px; background: var(--empty-bg); border: 1px dashed var(--line); border-radius: 0; }
.server-loading { color: var(--muted); }
.empty-mark { display: grid; place-items: center; width: 58px; height: 58px; flex: 0 0 58px; background: var(--accent-soft); border-radius: 0; color: var(--purple); font-size: .75rem; font-weight: 900; }
.empty-mark img { width: 58px; height: 58px; object-fit: contain; }
.server-empty h3 { margin: 0 0 3px; font-size: 1.05rem; }
.server-empty p { margin: 0; color: var(--muted); }
.server-card { display: grid; grid-template-columns: minmax(220px, 1.1fr) minmax(380px, 1.2fr) auto; gap: 28px; align-items: center; padding: 22px 24px; background: var(--navy-900); border: 1px solid var(--line); border-radius: 0; animation: card-in .28s ease both; transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease; }
.server-card:hover { border-color: color-mix(in srgb, var(--purple) 38%, var(--line)); box-shadow: var(--shadow); transform: translateY(-2px); }
.server-card.is-online { border-left: 4px solid var(--success); }
.server-card.is-offline { border-left: 4px solid var(--danger); }
.server-card.is-loading { border-left: 4px solid var(--purple); }
.server-identity { min-width: 0; }
.server-state { display: inline-flex; align-items: center; gap: 7px; margin-bottom: 4px; color: var(--muted); font-size: .75rem; font-weight: 800; text-transform: uppercase; }
.server-state::before { content: ""; width: 8px; height: 8px; border-radius: 0; background: #656c79; }
.is-online .server-state { color: var(--success); }
.is-online .server-state::before { background: var(--success); }
.is-offline .server-state { color: var(--danger); }
.is-offline .server-state::before { background: var(--danger); }
.is-loading .server-state { color: var(--purple); }
.is-loading .server-state::before { background: var(--purple); }
.server-identity h3 { margin: 0; overflow: hidden; font-size: 1.08rem; text-overflow: ellipsis; white-space: nowrap; }
.server-address { margin: 4px 0 0; color: var(--muted); font-family: Consolas, monospace; font-size: .78rem; }
.server-live-name { margin: 6px 0 0; color: var(--text-soft); font-size: .8rem; }
.server-facts { display: grid; grid-template-columns: repeat(4, minmax(70px, 1fr)); gap: 8px; margin: 0; }
.server-facts div { min-width: 0; padding: 8px 10px; background: var(--subtle-bg); border-radius: 0; }
.server-facts dt { color: var(--muted); font-size: .68rem; }
.server-facts dd { margin: 2px 0 0; overflow: hidden; color: var(--text); font-size: .82rem; font-weight: 700; text-overflow: ellipsis; white-space: nowrap; }
.server-actions { display: flex; gap: 8px; }
.server-actions button { min-height: 38px; padding: 8px 13px; }
.remove-button { border-color: rgba(239,139,146,.3); color: #ffb1b7; }
.remove-button:hover { background: rgba(239,139,146,.1); border-color: rgba(239,139,146,.5); }

.features { background: var(--navy-750); border-block: 1px solid var(--line); }
.feature-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.feature-card { min-height: 220px; padding: 28px; background: var(--navy-900); border: 1px solid var(--line); border-radius: 0; transition: border-color .22s ease, box-shadow .22s ease, transform .22s ease; }
.feature-card:hover { border-color: color-mix(in srgb, var(--purple) 44%, var(--line)); box-shadow: var(--shadow); transform: translateY(-4px); }
.feature-card:hover > span { transform: rotate(-6deg) scale(1.08); }
.feature-card > span { display: inline-grid; place-items: center; width: 38px; height: 38px; margin-bottom: 35px; background: var(--accent-soft); border-radius: 0; color: var(--purple); font-size: .74rem; font-weight: 900; transition: transform .22s ease; }
.feature-card h3 { margin: 0 0 8px; font-size: 1.2rem; }
.feature-card p { margin: 0; color: var(--muted); }

.install { background: var(--navy-800); }
.install-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 100px; align-items: start; }
.install-intro { max-width: 460px; margin: 17px 0 0; color: var(--muted); }
.install-list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.install-list li { display: grid; grid-template-columns: 44px 1fr; gap: 16px; padding: 21px 0; border-bottom: 1px solid var(--line); transition: padding-left .2s ease, border-color .2s ease; }
.install-list li:hover { padding-left: 8px; border-color: var(--purple); }
.install-list > li > span { display: grid; place-items: center; width: 36px; height: 36px; background: var(--purple); border-radius: 0; color: #171a24; font-size: .8rem; font-weight: 900; }
.install-list h3 { margin: 2px 0 3px; font-size: 1rem; }
.install-list p { margin: 0; color: var(--muted); font-size: .92rem; }

.download-section { padding-top: 24px; background: var(--navy-800); }
.download-panel { display: grid; grid-template-columns: auto 1fr auto; gap: 24px; align-items: center; padding: 34px; background: var(--navy-900); border: 1px solid var(--line); border-radius: 0; transition: border-color .25s ease, box-shadow .25s ease; }
.download-panel:hover { border-color: color-mix(in srgb, var(--purple) 38%, var(--line)); box-shadow: var(--shadow); }
.download-panel img { width: 78px; height: 78px; object-fit: contain; }
.download-panel h2 { font-size: 1.55rem; letter-spacing: -.02em; }
.download-panel p:last-child { margin: 7px 0 0; color: var(--muted); font-size: .88rem; }

.faq { background: var(--navy-750); border-top: 1px solid var(--line); }
.faq-grid { display: grid; grid-template-columns: .68fr 1fr; gap: 90px; align-items: start; }
.faq-list { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-item h3 { margin: 0; }
.faq-item button { width: 100%; display: flex; justify-content: space-between; gap: 24px; padding: 21px 0; border: 0; background: transparent; cursor: pointer; text-align: left; transition: color .18s ease; }
.faq-item button:hover, .faq-item button:focus-visible { color: var(--purple); }
.faq-item button span { font-size: 1rem; font-weight: 700; }
.faq-item button b { color: var(--purple); font-size: 1.35rem; font-weight: 400; transition: transform .15s ease; }
.faq-item button[aria-expanded="true"] b { transform: rotate(45deg); }
.faq-answer p { margin: -2px 44px 22px 0; color: var(--muted); }

.site-footer { padding: 32px 0; background: var(--navy-950); border-top: 1px solid rgba(255,255,255,.05); }
.footer-inner { display: grid; grid-template-columns: auto 1fr auto auto; gap: 36px; align-items: center; }
.footer-inner > p, .footer-inner > small { margin: 0; color: var(--muted); font-size: .82rem; }
.footer-inner nav { display: flex; gap: 20px; }
.footer-inner nav a { font-size: .82rem; }

.reveal { opacity: 0; filter: blur(3px); transform: translateY(34px) scale(.99); transition: opacity .65s ease, filter .65s ease, transform .65s cubic-bezier(.2,.72,.26,1); }
.reveal.is-visible { opacity: 1; filter: blur(0); transform: translateY(0) scale(1); }
.feature-grid .reveal:nth-child(2) { transition-delay: .06s; }
.feature-grid .reveal:nth-child(3) { transition-delay: .12s; }
.feature-grid .reveal:nth-child(4) { transition-delay: .18s; }

@keyframes header-in {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes hero-rise {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes logo-float {
    0%, 100% { transform: translateY(-50%); }
    50% { transform: translateY(calc(-50% - 12px)); }
}

@keyframes card-in {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 1050px) {
    .hero-grid { gap: 55px; }
    .add-server-form { grid-template-columns: 1fr 1fr 120px; }
    .field-name { grid-column: 1 / -1; }
    .server-card { grid-template-columns: 1fr auto; }
    .server-facts { grid-row: 2; grid-column: 1 / -1; }
    .server-actions { grid-column: 2; grid-row: 1; }
}

@media (max-width: 820px) {
    :root { --shell: min(100% - 32px, 680px); }
    .header-inner { display: flex; justify-content: space-between; gap: 18px; }
    .header-download { display: none; }
    .menu-toggle { display: grid; position: relative; z-index: 102; align-content: center; gap: 6px; width: 42px; height: 38px; padding: 0 10px; border: 1px solid var(--line); border-radius: 0; background: transparent; cursor: pointer; }
    .menu-toggle > span:not(.sr-only) { display: block; height: 2px; background: var(--text); }
    .site-nav { position: fixed; inset: var(--header-height) 0 auto; display: none; flex-direction: column; align-items: stretch; gap: 0; padding: 12px 16px 20px; background: var(--navy-900); border-bottom: 1px solid var(--line); }
    .site-nav.is-open { display: flex; animation: menu-in .2s ease-out both; }
    .site-nav a { padding: 13px 10px; border-bottom: 1px solid var(--line); border-radius: 0; }
    .site-nav a.is-active::after { inset: auto 10px 5px; }
    .hero { padding: 70px 0; }
    .hero-grid { grid-template-columns: 1fr; gap: 38px; }
    .hero-actions { max-width: 520px; }
    .section { padding: 68px 0; }
    .section-heading { align-items: start; flex-direction: column; }
    .add-server-form { grid-template-columns: 1fr 120px; }
    .field-name, .field-host { grid-column: 1 / -1; }
    .server-toolbar { align-items: stretch; flex-direction: column; gap: 8px; }
    .server-search { width: 100%; }
    .server-toolbar > p { margin: 0; }
    .feature-grid { grid-template-columns: 1fr; }
    .feature-card { min-height: 0; }
    .install-grid, .faq-grid { grid-template-columns: 1fr; gap: 44px; }
    .download-panel { grid-template-columns: auto 1fr; }
    .download-panel > .button { grid-column: 1 / -1; }
    .footer-inner { grid-template-columns: 1fr; gap: 18px; }
}

@keyframes menu-in {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 560px) {
    :root { --shell: calc(100% - 24px); }
    .brand img { width: 35px; height: 35px; }
    .brand strong { font-size: .92rem; }
    .theme-toggle [data-theme-label] { display: none; }
    .hero { padding: 56px 0 60px; }
    .hero-mark { right: -120px; width: 430px; height: 430px; }
    h1 { font-size: clamp(2.65rem, 13vw, 3.7rem); }
    h2 { font-size: clamp(1.85rem, 9vw, 2.6rem); }
    .hero-intro { font-size: 1.04rem; }
    .hero-actions .button { align-items: flex-start; flex-direction: column; justify-content: center; }
    .button-large small { margin: 5px 0 0; }
    .section { padding: 56px 0; }
    .add-server-panel { padding: 17px; }
    .add-server-form { grid-template-columns: 1fr; }
    .field-name, .field-host, .field-port, .add-server-button { grid-column: 1; }
    .server-card { grid-template-columns: 1fr; gap: 17px; padding: 19px; }
    .server-actions { grid-column: 1; grid-row: auto; }
    .server-actions .button { flex: 1; }
    .server-facts { grid-row: auto; grid-column: 1; grid-template-columns: repeat(2, 1fr); }
    .feature-card { padding: 22px; }
    .feature-card > span { margin-bottom: 24px; }
    .download-panel { grid-template-columns: 1fr; text-align: center; }
    .download-panel img { margin-inline: auto; }
    .download-panel > .button { grid-column: 1; }
    .footer-inner nav { flex-wrap: wrap; }
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
    .reveal { opacity: 1; transform: none; }
}
