/* ═══════════════════════════════════════════════════════════════
   MEGA-STACK Brand Alignment — Authelia Portal
   ═══════════════════════════════════════════════════════════════
   Dashboard brand-variables.css'ten türetilmiş.
   Navy #003366 + Sky #38bdf8 + Koyu Katmanlar
   ═══════════════════════════════════════════════════════════════ */

/* ── Body & Root ── */
body {
    background: #060d1a !important;
    color: #e2e8f0 !important;
}

/* Ambient glow (arka plan atmosferi) */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse at 20% 40%, rgba(0, 51, 102, 0.18) 0%, transparent 55%),
        radial-gradient(ellipse at 80% 20%, rgba(56, 189, 248, 0.06) 0%, transparent 50%),
        radial-gradient(ellipse at 50% 90%, rgba(0, 51, 102, 0.1) 0%, transparent 55%);
    pointer-events: none;
    z-index: 0;
}

#root {
    position: relative;
    z-index: 1;
}

/* ── Grid / Container backgrounds ── */
.MuiGrid-root {
    background: transparent !important;
}

/* ── Login Card (MuiPaper) ── */
.MuiPaper-root {
    background: rgba(15, 23, 42, 0.88) !important;
    backdrop-filter: blur(16px) !important;
    -webkit-backdrop-filter: blur(16px) !important;
    border: 1px solid rgba(0, 51, 102, 0.35) !important;
    border-radius: 16px !important;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.45),
        0 0 80px rgba(0, 51, 102, 0.08),
        inset 0 1px 0 rgba(255, 255, 255, 0.04) !important;
}

/* ── Typography ── */
.MuiTypography-root {
    color: #e2e8f0 !important;
}

h5.MuiTypography-root,
.MuiTypography-h5 {
    color: #ffffff !important;
    font-weight: 700 !important;
    letter-spacing: -0.02em !important;
}

h6.MuiTypography-root,
.MuiTypography-h6 {
    color: #ffffff !important;
    font-weight: 600 !important;
}

.MuiTypography-subtitle1,
.MuiTypography-subtitle2 {
    color: #94a3b8 !important;
}

.MuiTypography-body2 {
    color: #94a3b8 !important;
}

.MuiTypography-caption {
    color: #64748b !important;
}

/* ── Input Fields ── */
.MuiOutlinedInput-root {
    background: #0c1222 !important;
    border-radius: 10px !important;
}

.MuiOutlinedInput-root .MuiOutlinedInput-notchedOutline {
    border-color: rgba(0, 51, 102, 0.3) !important;
    transition: border-color 0.3s ease, box-shadow 0.3s ease !important;
}

.MuiOutlinedInput-root:hover .MuiOutlinedInput-notchedOutline {
    border-color: rgba(0, 51, 102, 0.5) !important;
}

.MuiOutlinedInput-root.Mui-focused .MuiOutlinedInput-notchedOutline {
    border-color: #38bdf8 !important;
    box-shadow: 0 0 0 3px rgba(56, 189, 248, 0.12) !important;
}

.MuiInputBase-root,
.MuiInputBase-input {
    color: #e2e8f0 !important;
}

.MuiInputLabel-root {
    color: #8aa2c4 !important;
}

.MuiInputLabel-root.Mui-focused {
    color: #38bdf8 !important;
}

/* ── Primary Buttons ── */
.MuiButtonBase-root.MuiButton-root {
    background: linear-gradient(135deg, #003366, #0a4a8a) !important;
    color: #ffffff !important;
    border: none !important;
    border-radius: 10px !important;
    text-transform: none !important;
    font-weight: 600 !important;
    letter-spacing: 0.02em !important;
    box-shadow: 0 4px 16px rgba(0, 51, 102, 0.3) !important;
    transition: all 0.3s ease !important;
}

.MuiButtonBase-root.MuiButton-root:hover {
    background: linear-gradient(135deg, #0a4a8a, #1a6bc4) !important;
    box-shadow: 0 6px 24px rgba(56, 189, 248, 0.25) !important;
    transform: translateY(-1px) !important;
}

.MuiButtonBase-root.MuiButton-root:active {
    transform: translateY(0) !important;
}

/* Text / ghost buttons (forgot password, reset, links) */
.MuiButton-text,
.MuiButtonBase-root.MuiButton-text {
    background: transparent !important;
    color: #38bdf8 !important;
    box-shadow: none !important;
    font-weight: 500 !important;
}

.MuiButton-text:hover,
.MuiButtonBase-root.MuiButton-text:hover {
    background: rgba(56, 189, 248, 0.08) !important;
    color: #0ea5e9 !important;
    box-shadow: none !important;
    transform: none !important;
}

/* ── Checkbox ── */
.MuiCheckbox-root {
    color: rgba(0, 51, 102, 0.5) !important;
}

.MuiCheckbox-root.Mui-checked {
    color: #38bdf8 !important;
}

/* ── Icon Buttons (show/hide password, etc.) ── */
.MuiIconButton-root {
    color: #94a3b8 !important;
    transition: color 0.2s ease !important;
}

.MuiIconButton-root:hover {
    color: #38bdf8 !important;
    background: rgba(56, 189, 248, 0.08) !important;
}

/* ── Links ── */
a:not(.MuiButtonBase-root) {
    color: #38bdf8 !important;
    text-decoration: none !important;
    transition: color 0.2s !important;
}

a:not(.MuiButtonBase-root):hover {
    color: #0ea5e9 !important;
}

/* ── Alerts ── */
.MuiAlert-root {
    border-radius: 10px !important;
    border: 1px solid rgba(0, 51, 102, 0.25) !important;
    backdrop-filter: blur(8px) !important;
}

/* ── Snackbar ── */
.MuiSnackbarContent-root {
    background: rgba(15, 23, 42, 0.95) !important;
    border: 1px solid rgba(0, 51, 102, 0.3) !important;
    border-radius: 10px !important;
    color: #e2e8f0 !important;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4) !important;
}

/* ── Circular Progress (loading) ── */
.MuiCircularProgress-root {
    color: #38bdf8 !important;
}

/* ── Touch Ripple ── */
.MuiTouchRipple-root .MuiTouchRipple-ripple .MuiTouchRipple-child {
    background-color: rgba(56, 189, 248, 0.3) !important;
}

/* ── Logo Enhancement ── */
img[src*="logo"] {
    width: 180px !important;
    height: auto !important;
}

img[src*="logo"]:hover {
    filter: drop-shadow(0 0 30px rgba(56, 189, 248, 0.25)) !important;
}

/* ── Footer / Powered-by ── */
footer,
footer * {
    color: #64748b !important;
}

footer a {
    color: #8aa2c4 !important;
}

footer a:hover {
    color: #38bdf8 !important;
}

/* ── Selection ── */
::selection {
    background: rgba(56, 189, 248, 0.3);
    color: #ffffff;
}

/* ── Scrollbar ── */
::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

::-webkit-scrollbar-track {
    background: #060d1a;
}

::-webkit-scrollbar-thumb {
    background: rgba(0, 51, 102, 0.4);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: rgba(0, 51, 102, 0.6);
}

/* ── Mobile Responsive ── */
@media (max-width: 600px) {
    .MuiPaper-root {
        margin: 8px !important;
        border-radius: 12px !important;
    }

    .MuiButtonBase-root.MuiButton-root {
        border-radius: 8px !important;
    }
}