/**
 * GeneralsX Authentication Portal Stylesheet
 * Dark, Military Sci-Fi & Premium Glassmorphic Aesthetic
 */

:root {
    --bg-dark: #07090e;
    --card-bg: rgba(13, 17, 26, 0.88);
    --card-border: rgba(255, 170, 0, 0.25);
    --card-border-focus: rgba(255, 170, 0, 0.6);
    --primary-gold: #ffaa00;
    --primary-gold-hover: #ffbb33;
    --discord-blurple: #5865F2;
    --discord-hover: #4752c4;
    --discord-active: #3c45a5;
    --text-main: #f0f4f8;
    --text-muted: #8b9bb4;
    --text-dim: #5c6b84;
    --success-green: #2ecc71;
    --danger-red: #e74c3c;
    --font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-family);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow-x: hidden;
}

/* Atmospheric Background with GeneralsX Splash */
.bg-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: 
        linear-gradient(180deg, rgba(7, 9, 14, 0.82) 0%, rgba(7, 9, 14, 0.94) 100%),
        url('/assets/images/splash2.png') center center / cover no-repeat;
    z-index: -1;
    filter: blur(2px);
    transform: scale(1.02);
}

.auth-container {
    width: 100%;
    max-width: 460px;
    padding: 24px;
    margin: auto;
    z-index: 10;
}

/* Glassmorphic Auth Card */
.auth-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 40px 32px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7), 0 0 30px rgba(255, 170, 0, 0.08);
    text-align: center;
    position: relative;
    overflow: hidden;
    animation: fadeIn 0.4s ease-out;
}

.auth-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-gold), transparent);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Logo */
.logo-wrapper {
    margin-bottom: 20px;
    display: inline-block;
    position: relative;
}

.auth-logo {
    width: 88px;
    height: 88px;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    border: 1px solid rgba(255, 170, 0, 0.3);
    transition: transform 0.3s ease;
}

.auth-logo:hover {
    transform: scale(1.04);
}

/* Typography */
h1.auth-title {
    font-size: 1.45rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    color: #fff;
    margin-bottom: 6px;
    text-transform: uppercase;
}

h1.auth-title span {
    color: var(--primary-gold);
}

p.auth-subtitle {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 24px;
}

/* Session Badge */
.session-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 170, 0, 0.08);
    border: 1px solid rgba(255, 170, 0, 0.2);
    border-radius: 20px;
    padding: 6px 14px;
    font-size: 0.78rem;
    color: var(--primary-gold);
    font-family: var(--font-mono);
    margin-bottom: 24px;
}

.session-indicator {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--success-green);
    box-shadow: 0 0 8px var(--success-green);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.85); }
}

/* Buttons */
.btn-discord {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    width: 100%;
    padding: 14px 20px;
    background-color: var(--discord-blurple);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 1.05rem;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
    box-shadow: 0 4px 16px rgba(88, 101, 242, 0.4);
}

.btn-discord:hover {
    background-color: var(--discord-hover);
    transform: translateY(-2px);
    box-shadow: 0 6px 22px rgba(88, 101, 242, 0.6);
}

.btn-discord:active {
    background-color: var(--discord-active);
    transform: translateY(0);
}

.btn-discord svg {
    width: 24px;
    height: 24px;
}

/* Security Notice Box */
.security-notice {
    margin-top: 24px;
    padding: 12px 14px;
    border-radius: 8px;
    background: rgba(231, 76, 60, 0.08);
    border: 1px solid rgba(231, 76, 60, 0.25);
    color: #f1948a;
    font-size: 0.78rem;
    line-height: 1.45;
    text-align: left;
}

.security-notice b {
    color: #fff;
}

/* User Profile Preview (Success State) */
.user-profile-box {
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 12px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
    text-align: left;
}

.user-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    border: 2px solid var(--primary-gold);
    box-shadow: 0 4px 12px rgba(0,0,0,0.5);
}

.user-details h3 {
    font-size: 1.05rem;
    font-weight: 600;
    color: #fff;
}

.user-details p {
    font-size: 0.82rem;
    color: var(--text-muted);
}

.user-details .badge-uid {
    display: inline-block;
    background: rgba(255, 170, 0, 0.15);
    color: var(--primary-gold);
    font-size: 0.72rem;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: var(--font-mono);
    margin-top: 4px;
}

/* Success / Error states */
.status-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px auto;
}

.status-icon.success {
    background: rgba(46, 204, 113, 0.15);
    color: var(--success-green);
    border: 2px solid var(--success-green);
    box-shadow: 0 0 20px rgba(46, 204, 113, 0.3);
}

.status-icon.error {
    background: rgba(231, 76, 60, 0.15);
    color: var(--danger-red);
    border: 2px solid var(--danger-red);
    box-shadow: 0 0 20px rgba(231, 76, 60, 0.3);
}

.status-icon svg {
    width: 32px;
    height: 32px;
}

.return-prompt {
    font-size: 0.95rem;
    color: #dce4ee;
    line-height: 1.5;
    margin-bottom: 20px;
}

.footer-text {
    margin-top: 24px;
    font-size: 0.76rem;
    color: var(--text-dim);
}

.footer-text a {
    color: var(--primary-gold);
    text-decoration: none;
}

.footer-text a:hover {
    text-decoration: underline;
}

/* Extended Policy & Code of Conduct Styles */
.policy-container {
    width: 100%;
    max-width: 760px;
    padding: 32px 20px;
    margin: 40px auto;
    z-index: 10;
}

.policy-card {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 40px 36px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.7);
    text-align: left;
    position: relative;
    overflow: hidden;
    line-height: 1.65;
}

.policy-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary-gold), transparent);
}

.policy-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.policy-header h1 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #fff;
}

.policy-header h1 span {
    color: var(--primary-gold);
}

.btn-back {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    color: var(--text-main);
    font-size: 0.85rem;
    text-decoration: none;
    transition: all 0.2s ease;
}

.btn-back:hover {
    background: rgba(255, 170, 0, 0.15);
    border-color: var(--primary-gold);
    color: #fff;
}

.policy-section {
    margin-bottom: 28px;
}

.policy-section h2 {
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--primary-gold);
    margin-bottom: 10px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.policy-section p {
    font-size: 0.92rem;
    color: #d0dbe7;
    margin-bottom: 12px;
}

.policy-section ul {
    list-style-type: none;
    margin-left: 4px;
    margin-bottom: 12px;
}

.policy-section li {
    font-size: 0.9rem;
    color: #b0c0d4;
    margin-bottom: 8px;
    padding-left: 20px;
    position: relative;
}

.policy-section li::before {
    content: '▪';
    color: var(--primary-gold);
    position: absolute;
    left: 4px;
}

.policy-callout {
    background: rgba(255, 170, 0, 0.06);
    border-left: 3px solid var(--primary-gold);
    border-radius: 4px 8px 8px 4px;
    padding: 12px 16px;
    margin-bottom: 24px;
    font-size: 0.88rem;
    color: #e2e8f0;
}
