/* WireTap panel — visual layer (depth, glass, landing-page energy) */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@500;600;700;800&display=swap');

:root {
    --bg-primary: #07080c;
    --bg-secondary: rgba(22, 27, 34, 0.88);
    --bg-card: rgba(28, 33, 40, 0.72);
    --bg-card-hover: rgba(36, 42, 52, 0.88);
    --sidebar-bg: rgba(12, 14, 20, 0.94);
    --sidebar-border: rgba(255, 255, 255, 0.08);
    --shadow-card: 0 8px 32px rgba(0, 0, 0, 0.32), inset 0 1px 0 rgba(255, 255, 255, 0.04);
    --shadow-elevated: 0 20px 50px rgba(0, 0, 0, 0.45);
    --accent-orange-glow: rgba(240, 136, 62, 0.4);
    --accent-blue-glow: rgba(88, 166, 255, 0.28);
    --surface-gradient: linear-gradient(165deg, rgba(34, 40, 50, 0.92) 0%, rgba(16, 19, 26, 0.96) 100%);
    --surface-gradient-soft: linear-gradient(145deg, rgba(30, 36, 46, 0.75) 0%, rgba(18, 21, 28, 0.85) 100%);
    --font-display: 'Outfit', 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

body {
    background: var(--bg-primary);
}

body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    background:
        radial-gradient(ellipse 55% 45% at 92% 8%, rgba(240, 136, 62, 0.14), transparent 55%),
        radial-gradient(ellipse 45% 40% at 8% 92%, rgba(88, 166, 255, 0.1), transparent 50%),
        radial-gradient(ellipse 35% 30% at 50% 50%, rgba(240, 136, 62, 0.04), transparent 60%);
}

body::after {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    opacity: 0.028;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ----- Sidebar ----- */
.sidebar {
    background: var(--sidebar-bg);
    border-right-color: var(--sidebar-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 4px 0 32px rgba(0, 0, 0, 0.35);
    z-index: 110;
}

.sidebar header {
    border-bottom-color: var(--sidebar-border);
}

.sidebar > header .header-text .name {
    font-family: var(--font-display);
    font-weight: 700;
}

.sidebar header .image-text .image {
    border: 1px solid var(--sidebar-border);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.25);
}

.sidebar li a {
    position: relative;
    border: 1px solid transparent;
}

.sidebar li a:hover {
    background: rgba(240, 136, 62, 0.1);
    border-color: rgba(240, 136, 62, 0.15);
}

.sidebar .nav-link.active a {
    background: linear-gradient(90deg, rgba(240, 136, 62, 0.18) 0%, rgba(240, 136, 62, 0.06) 100%);
    border-color: rgba(240, 136, 62, 0.25);
    box-shadow: inset 3px 0 0 var(--accent-orange);
}

.sidebar .nav-link.active .icon,
.sidebar .nav-link.active .text {
    color: var(--accent-orange);
}

.sidebar .menu-bar .bottom-content {
    border-top-color: var(--sidebar-border);
}

/* ----- Main shell ----- */
.home {
    position: relative;
    z-index: 1;
    background: transparent;
}

.dashboard-header .page-title,
.home > .text,
.onboarding-step-title,
.cloud-moderation-title,
.form-section-title {
    font-family: var(--font-display);
    letter-spacing: -0.03em;
}

.dashboard-header .page-title {
    background: linear-gradient(135deg, #f0f6fc 0%, #c9d1d9 55%, #f0883e 120%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.dashboard-header .page-subtitle {
    color: var(--text-secondary);
}

/* ----- Server context bar ----- */
.community-info,
.server-context-bar {
    background: var(--surface-gradient);
    border-color: var(--sidebar-border);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: var(--shadow-card);
}

.community-info .image img {
    border: 2px solid rgba(240, 136, 62, 0.25);
    box-shadow: 0 0 16px rgba(240, 136, 62, 0.15);
}

/* ----- Cards ----- */
.box-card,
.dashboard-stats .stat-card,
.form-section,
.panel-notice,
.onboarding-panel,
.onboarding-step-nav,
.quick-action-card {
    background: var(--surface-gradient);
    border-color: var(--sidebar-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: var(--shadow-card);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.box-card::before,
.dashboard-stats .stat-card::before,
.form-section::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.04) 0%, transparent 40%);
    opacity: 1;
}

.box-card,
.dashboard-stats .stat-card,
.form-section {
    position: relative;
    overflow: hidden;
}

.box-card:hover {
    border-color: rgba(240, 136, 62, 0.35);
    box-shadow: var(--shadow-elevated), 0 0 32px rgba(240, 136, 62, 0.08);
    transform: translateY(-3px);
}

.dashboard-stats .stat-card:hover {
    border-color: rgba(240, 136, 62, 0.35);
    box-shadow: var(--shadow-card), 0 0 24px rgba(240, 136, 62, 0.1);
    transform: translateY(-2px);
}

.box-card-selected {
    border-color: rgba(240, 136, 62, 0.55) !important;
    box-shadow: 0 0 0 1px rgba(240, 136, 62, 0.3), 0 12px 40px rgba(240, 136, 62, 0.12) !important;
}

.dashboard-stats .stat-card .stat-value {
    font-family: var(--font-display);
    background: linear-gradient(135deg, #e6edf3 30%, #f0883e 140%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* ----- Buttons ----- */
.quick-action-btn,
.box-card .button {
    background: linear-gradient(135deg, #f59a4f 0%, #e67a2e 50%, #d96a22 100%);
    box-shadow: 0 4px 16px rgba(240, 136, 62, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.quick-action-btn:hover,
.box-card .button:hover {
    background: linear-gradient(135deg, #ffab62 0%, #f0883e 50%, #e07830 100%);
    box-shadow: 0 6px 24px rgba(240, 136, 62, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.panel-btn-outline {
    background: rgba(255, 255, 255, 0.03);
    border-color: var(--sidebar-border);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
}

.panel-btn-outline:hover {
    background: rgba(240, 136, 62, 0.08);
    border-color: rgba(240, 136, 62, 0.4);
    box-shadow: 0 0 20px rgba(240, 136, 62, 0.12);
}

/* ----- Inputs ----- */
.panel-input,
.panel-textarea,
.quick-action-input,
.quick-action-select {
    background: rgba(13, 17, 23, 0.65);
    border-color: var(--sidebar-border);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.2);
}

.panel-input:focus,
.panel-textarea:focus,
.quick-action-input:focus,
.quick-action-select:focus {
    border-color: rgba(240, 136, 62, 0.55);
    box-shadow: 0 0 0 3px rgba(240, 136, 62, 0.15), inset 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* ----- Badges & notices ----- */
.status-badge.badge-active {
    background: rgba(63, 185, 80, 0.18);
    box-shadow: 0 0 12px rgba(63, 185, 80, 0.15);
}

.status-badge.badge-trial {
    background: rgba(88, 166, 255, 0.18);
    box-shadow: 0 0 12px var(--accent-blue-glow);
}

.panel-notice {
    background: var(--surface-gradient-soft);
}

.panel-notice-success {
    background: linear-gradient(135deg, rgba(63, 185, 80, 0.08) 0%, rgba(28, 33, 40, 0.9) 100%);
}

.panel-notice-warning {
    background: linear-gradient(135deg, rgba(240, 136, 62, 0.1) 0%, rgba(28, 33, 40, 0.9) 100%);
}

/* ----- Tables ----- */
.table-container {
    background: var(--surface-gradient);
    border: 1px solid var(--sidebar-border);
    border-radius: var(--radius-lg);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: var(--shadow-card);
    overflow: hidden;
}

.table-container table thead {
    background: rgba(255, 255, 255, 0.03);
}

.table-container table tbody tr:hover {
    background: rgba(240, 136, 62, 0.06);
}

/* ----- Onboarding ----- */
.onboarding-step-nav.is-current {
    border-color: rgba(240, 136, 62, 0.5);
    box-shadow: 0 0 24px rgba(240, 136, 62, 0.12), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.onboarding-step-nav.is-done {
    border-color: rgba(63, 185, 80, 0.4);
    box-shadow: 0 0 16px rgba(63, 185, 80, 0.08);
}

.onboarding-step-nav.is-current .onboarding-step-num {
    background: linear-gradient(135deg, #f59a4f, #e67a2e);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 4px 12px rgba(240, 136, 62, 0.4);
}

.onboarding-panel {
    border-color: var(--sidebar-border);
    box-shadow: var(--shadow-elevated);
}

.onboarding-cfg-block {
    background: rgba(13, 17, 23, 0.75);
    border-color: rgba(240, 136, 62, 0.2);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

/* ----- Cloud moderation card ----- */
.cloud-moderation-card {
    background: var(--surface-gradient);
    border-color: var(--sidebar-border);
    box-shadow: var(--shadow-elevated);
}

.cloud-status-live {
    box-shadow: 0 0 20px rgba(61, 214, 140, 0.25);
}

/* ----- Billing ----- */
.billing-plan-card,
.pricing-card {
    background: var(--surface-gradient) !important;
    border-color: var(--sidebar-border) !important;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: var(--shadow-card);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.billing-plan-card:hover,
.pricing-card:hover {
    border-color: rgba(240, 136, 62, 0.35) !important;
    box-shadow: var(--shadow-elevated), 0 0 28px rgba(240, 136, 62, 0.08);
    transform: translateY(-3px);
}

/* ----- Login ----- */
.login-page {
    background: var(--bg-primary);
}

.login-card {
    background: var(--surface-gradient);
    border-color: var(--sidebar-border);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: var(--shadow-elevated);
    overflow: hidden;
}

.login-card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: inherit;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.05) 0%, transparent 45%);
}

.login-card .title {
    font-family: var(--font-display);
    background: linear-gradient(135deg, #f0f6fc 0%, #f0883e 120%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.login-card .discord-button {
    background: linear-gradient(135deg, #f59a4f 0%, #e67a2e 50%, #d96a22 100%);
    box-shadow: 0 4px 16px rgba(240, 136, 62, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.login-card .discord-button:hover {
    background: linear-gradient(135deg, #ffab62 0%, #f0883e 50%, #e07830 100%);
    box-shadow: 0 6px 24px rgba(240, 136, 62, 0.45);
}

/* ----- Dashboard panels ----- */
.dash-panel,
.active-incident-card {
    background: var(--surface-gradient);
    border-color: var(--sidebar-border);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    box-shadow: var(--shadow-card);
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.dash-panel:hover,
.active-incident-card:hover {
    border-color: rgba(255, 255, 255, 0.12);
    box-shadow: var(--shadow-card), 0 0 24px rgba(88, 166, 255, 0.06);
}

.dash-panel-title,
.active-incident-header h3 {
    font-family: var(--font-display);
    letter-spacing: -0.02em;
}

.dash-review-banner {
    background: linear-gradient(135deg, rgba(240, 136, 62, 0.12) 0%, rgba(28, 33, 40, 0.9) 100%) !important;
    border-color: rgba(240, 136, 62, 0.3) !important;
}

.dash-alert-pill {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.staff-table-wrap {
    border-radius: var(--radius-lg);
    overflow: hidden;
    border: 1px solid var(--sidebar-border);
    box-shadow: var(--shadow-card);
}

.staff-table th {
    background: rgba(255, 255, 255, 0.04);
}

.rcon-verified-badge {
    background: rgba(63, 185, 80, 0.1);
    border: 1px solid rgba(63, 185, 80, 0.35);
    box-shadow: 0 0 20px rgba(63, 185, 80, 0.1);
}
