:root {
    --bg: #071018;
    --bg-deep: #03070d;
    --panel: rgba(10, 18, 28, 0.82);
    --panel-strong: rgba(14, 24, 37, 0.94);
    --line: rgba(112, 215, 255, 0.2);
    --line-strong: rgba(112, 215, 255, 0.4);
    --text: #edf4ff;
    --text-soft: rgba(237, 244, 255, 0.72);
    --text-dim: rgba(237, 244, 255, 0.52);
    --accent: #56f1c9;
    --accent-strong: #76c7ff;
    --warn: #ffb86c;
    --danger: #ff6f7d;
    --success: #7cf3b4;
    --shadow: 0 30px 80px rgba(0, 0, 0, 0.45);
    --font-display: "Orbitron", "Trebuchet MS", sans-serif;
    --font-body: "Space Grotesk", "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
}

html {
    color-scheme: dark;
}

body {
    margin: 0;
    min-height: 100vh;
    background:
        radial-gradient(
            circle at top,
            rgba(86, 241, 201, 0.14),
            transparent 30%
        ),
        radial-gradient(
            circle at right,
            rgba(118, 199, 255, 0.16),
            transparent 28%
        ),
        linear-gradient(180deg, #08121d 0%, #04070d 56%, #02050a 100%);
    color: var(--text);
    font-family: var(--font-body);
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(rgba(255, 255, 255, 0.02) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.02) 1px, transparent 1px);
    background-size: 48px 48px;
    mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.6), transparent 95%);
}

a {
    color: var(--accent);
}

button,
input,
textarea {
    font: inherit;
}

#root {
    min-height: 100vh;
}

.app-shell {
    position: relative;
    max-width: 1320px;
    margin: 0 auto;
    padding: 48px 20px 72px;
}

.background-grid {
    position: absolute;
    inset: 0;
    background: radial-gradient(
        circle at center,
        rgba(86, 241, 201, 0.06),
        transparent 60%
    );
    filter: blur(40px);
    z-index: 0;
}

.panel {
    position: relative;
    z-index: 1;
    background: linear-gradient(
        180deg,
        rgba(15, 25, 39, 0.92),
        rgba(8, 14, 22, 0.88)
    );
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.hero-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 260px;
    gap: 24px;
    padding: 34px;
    overflow: hidden;
}

.hero-panel::after,
.request-card::after,
.form-panel::after,
.recent-panel::after {
    content: "";
    position: absolute;
    inset: 0;
    padding: 1px;
    background: linear-gradient(
        135deg,
        rgba(86, 241, 201, 0.35),
        rgba(118, 199, 255, 0.08),
        transparent 55%
    );
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    pointer-events: none;
}

.hero-copy h1,
.panel-header h2,
.form-intro h3,
.request-card h3 {
    font-family: var(--font-display);
    letter-spacing: 0.03em;
}

.eyebrow {
    margin: 0 0 10px;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.18em;
    font-size: 0.76rem;
}

.hero-copy h1 {
    margin: 0;
    max-width: 10ch;
    font-size: clamp(2.4rem, 6vw, 4.8rem);
    line-height: 0.95;
}

.lede,
.form-intro p,
.panel-subtitle,
.hero-copy p,
.request-card p,
.request-detail p,
.captcha-header p {
    color: var(--text-soft);
}

.lede {
    max-width: 62ch;
    margin: 18px 0 0;
    line-height: 1.6;
    font-size: 1rem;
}

.hero-metrics {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    margin-top: 28px;
}

.hero-metrics > div,
.hero-status {
    background: rgba(7, 13, 21, 0.72);
    border: 1px solid rgba(118, 199, 255, 0.16);
    padding: 16px 18px;
}

.metric-label,
.status-label {
    display: block;
    margin-bottom: 8px;
    color: var(--text-dim);
    text-transform: uppercase;
    font-size: 0.72rem;
    letter-spacing: 0.14em;
}

.hero-status {
    display: flex;
    align-items: center;
    gap: 14px;
    align-self: start;
    min-height: 100%;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 999px;
    background: var(--accent);
    box-shadow: 0 0 18px rgba(86, 241, 201, 0.8);
}

.workspace-grid {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
    gap: 24px;
    margin-top: 24px;
}

.form-panel,
.recent-panel {
    padding: 28px;
}

.panel-header h2,
.form-intro h3,
.request-card h3 {
    margin: 0;
}

.panel-header {
    margin-bottom: 24px;
}

.type-toggle {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.type-toggle-button,
.secondary-button,
.primary-button,
.submit-button {
    cursor: pointer;
    border: 0;
    transition:
        transform 180ms ease,
        box-shadow 180ms ease,
        border-color 180ms ease,
        background 180ms ease;
}

.type-toggle-button {
    padding: 16px 18px;
    border: 1px solid rgba(118, 199, 255, 0.18);
    background: rgba(5, 11, 18, 0.8);
    color: var(--text-soft);
    text-align: left;
}

.type-toggle-button:hover,
.secondary-button:hover,
.primary-button:hover,
.submit-button:hover {
    transform: translateY(-1px);
}

.type-toggle-button.is-active {
    background: linear-gradient(
        135deg,
        rgba(86, 241, 201, 0.18),
        rgba(118, 199, 255, 0.16)
    );
    border-color: rgba(86, 241, 201, 0.54);
    color: var(--text);
    box-shadow:
        0 0 0 1px rgba(86, 241, 201, 0.2),
        0 18px 36px rgba(0, 0, 0, 0.28);
}

.toggle-label {
    display: inline-block;
}

.toggle-label.is-pulsing {
    animation: toggle-pulse 520ms ease 2;
}

.form-intro {
    margin: 22px 0;
}

.form-hint {
    margin: 12px 0 0;
    padding: 10px 12px;
    border: 1px solid rgba(118, 199, 255, 0.2);
    background: rgba(8, 15, 24, 0.74);
    color: var(--text-soft);
    animation: form-hint-appear 180ms ease;
}

.form-hint.is-attention {
    border-color: rgba(255, 184, 108, 0.34);
    background: rgba(255, 184, 108, 0.08);
    color: #ffe3b8;
}

.request-form {
    display: grid;
    gap: 18px;
}

.request-form label {
    display: grid;
    gap: 8px;
}

.request-form span,
.captcha-title {
    color: var(--text-soft);
    font-size: 0.92rem;
}

input,
textarea {
    width: 100%;
    border: 1px solid rgba(118, 199, 255, 0.16);
    background: rgba(3, 8, 13, 0.9);
    color: var(--text);
    padding: 14px 16px;
    resize: vertical;
    min-height: 52px;
}

textarea {
    min-height: 122px;
}

input:focus,
textarea:focus {
    outline: 2px solid rgba(86, 241, 201, 0.3);
    border-color: rgba(86, 241, 201, 0.56);
}

input.is-invalid,
textarea.is-invalid {
    border-color: rgba(255, 111, 125, 0.72);
    box-shadow: 0 0 0 1px rgba(255, 111, 125, 0.24);
}

.field-error {
    color: #ffd0d4;
    font-size: 0.84rem;
    line-height: 1.4;
}

@keyframes form-hint-appear {
    from {
        opacity: 0;
        transform: translateY(4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes toggle-pulse {
    0% {
        transform: scale(1);
        text-shadow: none;
    }

    40% {
        transform: scale(1.04);
        text-shadow: 0 0 18px rgba(86, 241, 201, 0.55);
    }

    100% {
        transform: scale(1);
        text-shadow: none;
    }
}

.captcha-block {
    display: grid;
    gap: 16px;
    padding: 18px;
    background: rgba(4, 10, 16, 0.72);
    border: 1px solid rgba(118, 199, 255, 0.14);
}

.captcha-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    gap: 16px;
}

.captcha-frame {
    display: grid;
    place-items: center;
    min-height: 96px;
    background: rgba(2, 6, 10, 0.95);
    border: 1px dashed rgba(118, 199, 255, 0.24);
}

.captcha-image {
    width: 100%;
    max-width: 220px;
    height: auto;
}

.captcha-placeholder,
.empty-state {
    color: var(--text-dim);
    padding: 18px;
    background: rgba(5, 10, 17, 0.58);
    border: 1px dashed rgba(118, 199, 255, 0.14);
}

.empty-state.is-error,
.form-message.is-error {
    color: #ffd0d4;
    background: rgba(255, 111, 125, 0.12);
    border: 1px solid rgba(255, 111, 125, 0.24);
}

.form-notes {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.form-notes span,
.request-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(9, 16, 26, 0.85);
    border: 1px solid rgba(118, 199, 255, 0.16);
    color: var(--text-soft);
    font-size: 0.82rem;
}

.form-message {
    margin: 0;
    padding: 14px 16px;
}

.form-message.is-success {
    color: #ddffef;
    background: rgba(124, 243, 180, 0.12);
    border: 1px solid rgba(124, 243, 180, 0.22);
}

.secondary-button,
.primary-button,
.submit-button {
    min-height: 48px;
    padding: 12px 16px;
}

.secondary-button {
    background: rgba(8, 15, 24, 0.84);
    color: var(--text);
    border: 1px solid rgba(118, 199, 255, 0.18);
}

.primary-button,
.submit-button {
    background: linear-gradient(135deg, var(--accent), var(--accent-strong));
    color: #031117;
    font-weight: 700;
    box-shadow: 0 18px 36px rgba(86, 241, 201, 0.18);
}

.submit-button:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.request-list {
    display: grid;
    gap: 16px;
}

.request-card {
    position: relative;
    padding: 20px;
    background: linear-gradient(
        180deg,
        rgba(8, 14, 22, 0.96),
        rgba(6, 10, 17, 0.92)
    );
    border: 1px solid rgba(118, 199, 255, 0.12);
    overflow: hidden;
}

.request-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}

.request-card time {
    color: var(--text-dim);
    font-size: 0.86rem;
}

.request-badge {
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.request-badge.is-bug {
    border-color: rgba(255, 111, 125, 0.24);
    color: #ffd3d7;
}

.request-badge.is-feature {
    border-color: rgba(86, 241, 201, 0.28);
    color: #d8fff2;
}

.request-card p {
    margin-top: 10px;
    line-height: 1.6;
    white-space: pre-wrap;
}

.request-detail {
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid rgba(118, 199, 255, 0.12);
}

.request-detail strong {
    color: var(--warn);
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
}

.request-link {
    display: inline-flex;
    margin-top: 14px;
    color: var(--accent);
    text-decoration: none;
}

.request-link:hover {
    text-decoration: underline;
}

@media (max-width: 1080px) {
    .hero-panel,
    .workspace-grid {
        grid-template-columns: 1fr;
    }

    .hero-copy h1 {
        max-width: none;
    }
}

@media (max-width: 720px) {
    .app-shell {
        padding: 24px 14px 42px;
    }

    .hero-panel,
    .form-panel,
    .recent-panel {
        padding: 22px;
    }

    .hero-metrics {
        grid-template-columns: 1fr;
    }

    .captcha-header {
        flex-direction: column;
    }

    .type-toggle {
        grid-template-columns: 1fr;
    }
}
