/* ==============================
   1. Reset & Variables
============================== */

:root {
    --primary: #6366f1;
    --primary-dark: #4f46e5;
    --text: #1e293b;
    --text-muted: #64748b;
    --background: #f8faff;
    --white: #ffffff;
    --success: #22c55e;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI",
        Roboto, "Helvetica Neue", Arial, sans-serif;
    color: var(--text);
    background: var(--background);
    -webkit-font-smoothing: antialiased;
}

/* ==============================
   2. Main Layout
============================== */

.maintenance {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    min-height: 100svh;
    padding: 40px 20px;
    overflow: hidden;
    isolation: isolate;

    background:
        radial-gradient(
            ellipse at 10% 10%,
            rgba(129, 140, 248, 0.13),
            transparent 45%
        ),
        radial-gradient(
            ellipse at 90% 90%,
            rgba(56, 189, 248, 0.12),
            transparent 40%
        ),
        var(--background);
}

.maintenance-card {
    position: relative;
    z-index: 2;
    width: 100%;
    max-width: 600px;
    padding: 52px 44px 32px;
    text-align: center;

    background: rgba(255, 255, 255, 0.86);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 28px;

    box-shadow:
        0 25px 80px rgba(30, 41, 59, 0.07),
        0 4px 16px rgba(30, 41, 59, 0.03);

    animation: fade-up 0.8s ease-out both;
}

/* ==============================
   3. Maintenance Icon
============================== */

.icon-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 112px;
    height: 112px;
    margin: 0 auto 28px;

    color: var(--primary);
    background: linear-gradient(
        145deg,
        #eef2ff,
        #e0e7ff
    );
    border: 1px solid rgba(99, 102, 241, 0.12);
    border-radius: 32px;

    animation: float 3.5s ease-in-out infinite;
}

.maintenance-icon {
    width: 72px;
    height: 72px;
}

/* ==============================
   4. Status Badge
============================== */

.status {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    margin-bottom: 22px;
    padding: 9px 15px;

    color: var(--primary-dark);
    background: #eef2ff;
    border: 1px solid #e0e7ff;
    border-radius: 999px;

    font-size: 11px;
    font-weight: 750;
    letter-spacing: 1.3px;
}

.status-dot {
    width: 8px;
    height: 8px;
    flex-shrink: 0;

    background: var(--primary);
    border-radius: 50%;

    animation: pulse 1.8s ease-in-out infinite;
}

/* ==============================
   5. Content
============================== */

h1 {
    margin-bottom: 22px;

    color: var(--text);
    font-size: clamp(36px, 6vw, 48px);
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -1.8px;
}

h1 span {
    color: var(--primary);
}

.description {
    max-width: 440px;
    margin: 0 auto;

    color: var(--text-muted);
    font-size: 15px;
    line-height: 1.9;
}

.divider {
    width: 48px;
    height: 3px;
    margin: 28px auto;

    background: linear-gradient(
        90deg,
        #a5b4fc,
        var(--primary)
    );
    border-radius: 99px;
}

.notice {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;

    margin-bottom: 26px;

    color: #475569;
    font-size: 13px;
    line-height: 1.6;
}

.notice svg {
    flex-shrink: 0;
    color: var(--primary);
}

/* ==============================
   6. Reload Button
============================== */

.reload-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;

    min-height: 50px;
    padding: 0 25px;

    color: var(--white);
    background: linear-gradient(
        135deg,
        #818cf8,
        var(--primary-dark)
    );
    border: none;
    border-radius: 14px;

    font-family: inherit;
    font-size: 14px;
    font-weight: 650;

    cursor: pointer;

    box-shadow: 0 8px 20px rgba(99, 102, 241, 0.22);

    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease,
        filter 0.2s ease;
}

.reload-button:hover {
    transform: translateY(-2px);
    filter: brightness(1.05);
    box-shadow: 0 12px 26px rgba(99, 102, 241, 0.3);
}

.reload-button:active {
    transform: translateY(0);
}

.reload-button:focus-visible {
    outline: 3px solid #a5b4fc;
    outline-offset: 4px;
}

.reload-button svg {
    transition: transform 0.5s ease;
}

.reload-button:hover svg {
    transform: rotate(180deg);
}

/* ==============================
   7. Footer
============================== */

footer {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;

    margin-top: 42px;
    padding-top: 22px;

    color: #94a3b8;
    border-top: 1px solid #f1f5f9;

    font-size: 12px;
    line-height: 1.6;
}

.footer-dot {
    width: 6px;
    height: 6px;
    flex-shrink: 0;

    background: var(--success);
    border-radius: 50%;
}

/* ==============================
   8. Background Decorations
============================== */

.decoration {
    position: absolute;
    z-index: 1;

    border: 1px solid rgba(99, 102, 241, 0.1);
    border-radius: 50%;

    pointer-events: none;
}

.decoration-1 {
    top: -140px;
    left: -100px;
    width: 350px;
    height: 350px;
}

.decoration-2 {
    right: -120px;
    bottom: -160px;
    width: 420px;
    height: 420px;
}

/* ==============================
   9. Animations
============================== */

@keyframes fade-up {
    from {
        opacity: 0;
        transform: translateY(24px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
        box-shadow: 0 0 0 0 rgba(99, 102, 241, 0.3);
    }

    50% {
        opacity: 0.7;
        box-shadow: 0 0 0 6px rgba(99, 102, 241, 0);
    }
}

/* ==============================
   10. Responsive
============================== */

@media (max-width: 600px) {
    .maintenance {
        padding: 24px 16px;
    }

    .maintenance-card {
        padding: 36px 22px 24px;
        border-radius: 22px;
    }

    .icon-wrapper {
        width: 92px;
        height: 92px;
        margin-bottom: 24px;
        border-radius: 26px;
    }

    .maintenance-icon {
        width: 60px;
        height: 60px;
    }

    .status {
        margin-bottom: 20px;
        padding: 8px 12px;
        font-size: 10px;
        letter-spacing: 1px;
    }

    h1 {
        margin-bottom: 18px;
        font-size: clamp(32px, 9vw, 40px);
        letter-spacing: -1.2px;
    }

    .description {
        font-size: 14px;
        line-height: 1.8;
    }

    .divider {
        margin: 24px auto;
    }

    .notice {
        align-items: flex-start;
        font-size: 12px;
    }

    .reload-button {
        width: 100%;
        min-height: 48px;
    }

    footer {
        margin-top: 30px;
        padding-top: 20px;
        font-size: 11px;
    }
}

/* Tôn trọng cài đặt giảm chuyển động của người dùng */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}

.company-brand {
    margin-bottom: 32px;
}

.company-name {
    color: #1e293b;
    font-size: 18px;
    font-weight: 800;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}