.page-404 {
    --p404-green: #0ca554;
    --p404-green-dark: #088647;
    --p404-green-soft: rgba(12, 165, 84, 0.12);
    --p404-text: #151515;
    --p404-muted: #6b7280;

    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.25rem;
    background:
        radial-gradient(circle at 15% 20%, rgba(12, 165, 84, 0.14), transparent 28%),
        radial-gradient(circle at 85% 80%, rgba(12, 165, 84, 0.1), transparent 32%),
        linear-gradient(180deg, #f8fbf9 0%, #ffffff 45%, #f3faf6 100%);
    font-family: "Inter", sans-serif;
}

.page-404__card {
    width: min(720px, 100%);
    text-align: center;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(12, 165, 84, 0.12);
    border-radius: 28px;
    padding: clamp(2rem, 5vw, 3.5rem);
    box-shadow: 0 24px 60px rgba(21, 21, 21, 0.08);
    backdrop-filter: blur(8px);
}

.page-404__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 0.9rem;
    border-radius: 999px;
    background: var(--p404-green-soft);
    color: var(--p404-green-dark);
    font-size: 0.92rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.page-404__code {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(0.75rem, 3vw, 1.25rem);
    margin-bottom: 1rem;
}

.page-404__digit {
    font-size: clamp(4rem, 14vw, 7rem);
    line-height: 1;
    font-weight: 800;
    color: var(--p404-text);
    letter-spacing: -0.06em;
}

.page-404__icon {
    width: clamp(4.5rem, 16vw, 7rem);
    height: clamp(4.5rem, 16vw, 7rem);
    border-radius: 24px;
    background: linear-gradient(145deg, var(--p404-green), var(--p404-green-dark));
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: clamp(2rem, 7vw, 3rem);
    box-shadow: 0 18px 40px rgba(12, 165, 84, 0.28);
    animation: page404Float 4s ease-in-out infinite;
}

.page-404__title {
    font-size: clamp(1.5rem, 4vw, 2rem);
    color: var(--p404-text);
    margin: 0 0 0.75rem;
    font-weight: 700;
}

.page-404__text {
    margin: 0 auto 2rem;
    max-width: 34rem;
    color: var(--p404-muted);
    font-size: clamp(1rem, 2.4vw, 1.08rem);
    line-height: 1.7;
}

.page-404__actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    justify-content: center;
}

.page-404__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-width: 210px;
    padding: 0.9rem 1.4rem;
    border-radius: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.page-404__btn--primary {
    background: var(--p404-green);
    color: #fff;
    box-shadow: 0 12px 24px rgba(12, 165, 84, 0.24);
}

.page-404__btn--primary:hover {
    background: var(--p404-green-dark);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 16px 28px rgba(12, 165, 84, 0.28);
}

.page-404__btn--ghost {
    background: #fff;
    color: var(--p404-text);
    border: 1px solid rgba(21, 21, 21, 0.08);
}

.page-404__btn--ghost:hover {
    color: var(--p404-green-dark);
    border-color: rgba(12, 165, 84, 0.25);
    transform: translateY(-2px);
}

.page-404__dots {
    display: flex;
    justify-content: center;
    gap: 0.45rem;
    margin-top: 2rem;
}

.page-404__dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(12, 165, 84, 0.25);
    animation: page404Pulse 1.6s ease-in-out infinite;
}

.page-404__dots span:nth-child(2) { animation-delay: 0.2s; }
.page-404__dots span:nth-child(3) { animation-delay: 0.4s; }

@keyframes page404Float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

@keyframes page404Pulse {
    0%, 100% { transform: scale(1); opacity: 0.45; }
    50% { transform: scale(1.25); opacity: 1; }
}

@media (max-width: 520px) {
    .page-404__actions {
        flex-direction: column;
    }

    .page-404__btn {
        width: 100%;
    }
}
