/* ============================================
   BRÄNNBOLLSARKIVET BUNDLE CSS
   Generated: 2026-01-22
   ============================================ */

/* =========================
   1. VARIABLES.CSS
   ========================= */

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

:root {
  /* =========================
     NHL PALETTE (GOLD & DARK)
     ========================= */
  
  /* Core Colors */
  --bg-main: #0a0c10; /* Deep dark blue/black */
  --bg-secondary: #12161f; /* Slightly lighter panel bg */
  --text-main: #f0f0f0;
  --text-muted: #8b9bb4;
  
  /* Guld - Metallisk/Elegant (Vegas Gold) */
  --gold-primary: #C5A065;    /* Klassisk metallisk guld */
  --gold-highlight: #E6C896;  /* Ljusare reflektion */
  --gold-shadow: #8A6D3B;     /* Mörkare brons/skugga */
  
  /* Gradienter */
  --gold-gradient: linear-gradient(135deg, #8A6D3B 0%, #C5A065 45%, #E6C896 100%);
  --gold-gradient-hover: linear-gradient(135deg, #A47F46 0%, #D4AF74 45%, #F0D5A8 100%);
  
  /* Accent Colors (Based on Gold Primary #C5A065 - RGB: 197, 160, 101) */
  --accent: var(--gold-primary);
  --accent-rgb: 197, 160, 101;
  --accent-hover: #e6c37d;
  --accent-bright: #f2d299;
  
  /* UI Elements */
  --panel-radius: 4px; /* Sharper corners for sports tech feel */
  --sidebar-width: 260px; /* Slightly wider for new menu */
  --mobile-breakpoint: 992px;
  
  /* Status Colors */
  --danger: #d93025;
  --success: #1e8e3e;
  --warning: #f9ab00;
  
  /* Layout Config */
  --cone-margin: 250px;
  --cone-offset-y: 100px;
  
  /* Backdrops */
  --backdrop-dark: rgba(10, 12, 16, 0.85);
  --glass-border: rgba(255, 255, 255, 0.08);

  /* Typografi */
  --font-family-main: "Inter", system-ui, sans-serif;
  --font-family-display: "Barlow Condensed", system-ui, sans-serif; /* Sportig NHL-font */
  --font-size-base: clamp(14px, 1.5vw, 16px);
  --font-size-lg: clamp(16px, 2vw, 18px);
  --font-size-xl: clamp(18px, 2.5vw, 22px);
  --font-size-2xl: clamp(22px, 3.5vw, 28px);
  --font-weight-regular: 400;
  --font-weight-semibold: 600;
  --font-weight-bold: 700;
  --font-weight-extrabold: 800;

  /* Spacing-skala */
  --space-2xs: 4px;
  --space-xs: 8px;
  --space-sm: 12px;
  --space-md: 16px;
  --space-lg: 20px;
  --space-xl: 24px;
  --space-2xl: 32px;
  --space-3xl: 48px;

  /* Radier */
  --radius-sm: 2px;
  --radius-md: 4px;
  --radius-lg: 8px;

  /* Alias för äldre variabelnamn i CSS */
  --color-text-main: var(--text-main);
  --color-accent: var(--accent);
  --color-accent-hover: var(--accent-hover);
  --color-text-disabled: #555;
  --border-light: rgba(255,255,255,0.1);
  
  /* Transparent Accents (Updated RGB: 197, 160, 101) */
  --accent-a-02: rgba(197, 160, 101, 0.02);
  --accent-a-05: rgba(197, 160, 101, 0.05);
  --accent-a-08: rgba(197, 160, 101, 0.08);
  --accent-a-10: rgba(197, 160, 101, 0.10);
  --accent-a-20: rgba(197, 160, 101, 0.20);
  --accent-a-30: rgba(197, 160, 101, 0.30);
  --accent-a-50: rgba(197, 160, 101, 0.50);
  
  /* Standard Utility Colors */
  --black: #000000;
  --white: #ffffff;
  --gray-666: #666666;
  --border-muted: #333333;
}

/* =========================
   2. UTILITIES.CSS
   ========================= */
.flex-gap { display: flex; gap: 10px; }
.flex-1 { flex: 1; }
.mt-30 { margin-top: 30px; }
.mb-30 { margin-bottom: 30px; }
.mb-15 { margin-bottom: 15px; }
.mt-20 { margin-top: 20px; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; margin-bottom: 15px; }
.grid-list { display: grid; gap: 20px; }
.grid-list-sm { display: grid; gap: 15px; }

.hidden { display: none !important; }

/* =========================
   3. UNIFIED-DESIGN.CSS
   ========================= */
/* Page Headers */
.page-header-container {
    margin-bottom: 30px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 20px;
}

.page-subtitle {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--gold-highlight);
    margin-bottom: 8px;
    font-weight: 700;
}

.page-title {
    font-family: var(--font-family-display);
    font-size: clamp(2rem, 6vw, 3rem);
    text-transform: uppercase;
    font-weight: 900;
    color: var(--white);
    line-height: 1.1;
    margin: 0;
    text-shadow: 0 4px 10px rgba(0,0,0,0.5);
}

/* Glass Panel Container - More Transparent */
.glass-panel {
    background: rgba(0, 0, 0, 0.2);
    border: none;
    border-radius: var(--panel-radius);
    padding: var(--space-2xl);
    box-shadow: none;
    position: relative;
    overflow: visible;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.content-section {
    padding: var(--space-2xl) 0;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

.glass-panel::before {
    display: none;
}

.glass-panel > * {
    position: relative;
    z-index: 1;
}

/* Archive Tabs */
.archive-tabs {
    display: flex;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--glass-border);
    padding-bottom: 10px;
    margin-bottom: 20px;
    
    /* Mobilanpassning: Horisontell scroll */
    overflow-x: auto;
    overflow-y: hidden;
    white-space: nowrap;
    -webkit-overflow-scrolling: touch; /* Mjuk scroll på iOS */
    scrollbar-width: none; /* Dölj scrollbar Firefox */
}
/* Dölj scrollbar Webkit */
.archive-tabs::-webkit-scrollbar {
    display: none;
}

.archive-tab-item {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0; /* Förhindra att flikar krymper */
}
.archive-tab {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 8px 12px;
    cursor: pointer;
    position: relative;
    white-space: nowrap; /* Förhindra radbrytning */
}
.archive-tab::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--gold-gradient);
    transition: width 0.3s ease;
}
.archive-tab:hover {
    color: var(--white);
}
.archive-tab:hover::after, .archive-tab.active::after {
    width: 100%;
}
.archive-tabs-admin {
    margin-left: auto;
}

.archive-tab-tools {
    display: flex;
    align-items: center;
    gap: 4px;
}

.archive-tab-icon-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 12px;
    padding: 0 4px;
}

.archive-tab-icon-btn:hover {
    color: var(--white);
}

.archive-field-label {
    color: var(--text-muted);
    font-size: 12px;
    margin-right: 6px;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.archive-field-select {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-main);
    border-radius: 4px;
    font-size: 12px;
    padding: 6px 8px;
    margin-right: 10px;
}

/* Player Info Panel - New Design */
#playerInfoPanel {
    background: transparent; /* Låt containern vara transparent */
    border: 1px solid var(--glass-border);
    border-radius: 4px;
    padding: 0; 
    margin-top: 0; 
    overflow: hidden; 
    box-shadow: 0 4px 20px rgba(0,0,0,0.3);
    height: 100%;
    display: flex;
    flex-direction: column;
}

.player-info-banner-container {
    background: linear-gradient(135deg, rgba(197, 160, 101, 0.15), rgba(0,0,0,0.4)); /* Återställd guld-gradient */
    padding: 20px;
    border-bottom: 1px solid var(--gold-primary-dim);
    position: relative;
}

.player-info-banner-container::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold-primary), transparent);
    opacity: 1; /* Återställd opacitet */
}

.player-info-name {
    font-family: var(--font-family-display);
    text-transform: uppercase;
    font-weight: 900;
    color: var(--white);
    font-size: 28px;
    line-height: 1;
    margin: 0 0 6px 0;
    letter-spacing: 0.5px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.player-info-position {
    font-family: var(--font-family-main);
    color: var(--gold-primary);
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Borttagen punkt före position */
.player-info-position::before {
    display: none;
}

.player-info-content {
    padding: 20px;
    flex: 1; /* Fyll ut resten av höjden */
}

/* Section Headers in Panel */
.player-info-section-title {
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-top: 15px;
    margin-bottom: 5px;
    border-left: 2px solid var(--gold-primary);
    padding-left: 8px;
}

.player-info-section-title:first-child {
    margin-top: 0;
}

.player-info-desc {
    color: var(--text-main);
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 15px;
    padding-left: 10px; /* Indent slightly to align with border */
    display: block;
}

.player-info-desc::first-letter {
    text-transform: uppercase;
}

/* Old classes kept for compatibility or removal */
.player-info-banner { display: none; }
.player-info-pill { display: none; }
.player-info-row { display: none; }

/* Specific Section Layouts */

/* News Layout */
.news-layout {
    display: grid;
    gap: 20px;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}

.news-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--glass-border);
    border-radius: 4px;
    padding: 20px;
    transition: all 0.3s ease;
}

.news-card:hover {
    background: rgba(255, 255, 255, 0.05);
    border-color: var(--gold-primary);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(197, 160, 101, 0.4);
}

/* Profile Layout */
.profile-container {
    max-width: 100%;
    margin: 0;
}

.profile-main-layout {
    display: flex;
    gap: 60px;
    align-items: flex-start;
}

.profile-form-side {
    flex: 1;
    max-width: 450px; /* Restore max-width for form */
}

.profile-photo-side {
    flex-shrink: 0;
}

.profile-photo-wrapper {
    position: relative;
    width: 160px;
}

.profile-photo-preview {
    width: 160px;
    height: 160px;
    background: rgba(0, 0, 0, 0.4);
    border: 2px solid var(--glass-border);
    border-radius: 8px; /* Back to rounded square */
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
}

.profile-photo-preview.has-image {
    border-color: var(--gold-primary);
    border-style: solid;
}

.profile-photo-preview:hover {
    border-color: var(--gold-highlight);
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
}

.profile-photo-preview img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-placeholder {
    color: var(--text-muted);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center;
    padding: 10px;
}

.photo-upload-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.profile-photo-preview:hover .photo-upload-overlay {
    opacity: 1;
}

.upload-icon-btn {
    background: var(--gold-primary);
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #000;
    cursor: pointer;
    transition: transform 0.2s ease, background 0.2s ease;
}

.upload-icon-btn:hover {
    transform: scale(1.1);
    background: var(--gold-highlight);
}

.upload-icon-btn svg {
    width: 20px;
    height: 20px;
}

.photo-loading-overlay {
    position: absolute;
    inset: 0;
    background: rgba(10, 12, 16, 0.8);
    display: none; 
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.spinner-small {
    width: 24px;
    height: 24px;
    border: 2px solid rgba(197, 160, 101, 0.2);
    border-top-color: var(--gold-primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.photo-actions-under {
    margin-top: 8px;
    display: flex;
    justify-content: center;
}

.btn-text-danger {
    background: none;
    border: none;
    color: var(--danger);
    font-size: 11px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: 1px;
    cursor: pointer;
    padding: 4px;
    opacity: 0.6;
    transition: opacity 0.2s;
}

.btn-text-danger:hover {
    opacity: 1;
}

.upload-status {
    font-size: 10px;
    color: var(--gold-primary);
    text-align: center;
    margin-top: 5px;
    min-height: 14px;
}

@media (max-width: 768px) {
    .profile-main-layout {
        flex-direction: column-reverse; /* Form first on mobile, then photo? or vice-versa? User said "enhetligt" */
        gap: 30px;
        align-items: center;
    }
    
    .profile-form-side {
        width: 100%;
        max-width: 100%;
    }
}

/* Player Modal Image */
.player-modal-image-container {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.4);
    border: 2px solid var(--gold-primary);
    overflow: hidden;
    flex-shrink: 0;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
}

.player-modal-image-container img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.player-modal-title-group h2 {
    font-family: var(--font-family-display);
    font-size: 24px;
    font-weight: 900;
    text-transform: uppercase;
    color: var(--white);
    margin: 0 0 2px 0;
    line-height: 1;
}

.player-modal-position {
    color: var(--gold-primary);
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: grid;
    gap: 20px;
    max-width: 400px;
}

/* Modal Styling */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.85);
    backdrop-filter: blur(8px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.crop-modal-content {
    background: var(--bg-secondary);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.modal-header {
    padding: 20px;
    border-bottom: 1px solid var(--glass-border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    font-family: var(--font-family-display);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 0;
}

.close-modal {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 28px;
    cursor: pointer;
    line-height: 1;
}

.crop-container {
    padding: 20px;
    background: #000;
    flex: 1;
    overflow: hidden;
    min-height: 300px;
    max-height: 500px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.crop-container img {
    max-width: 100%;
    display: block;
}

.modal-footer {
    padding: 20px;
    border-top: 1px solid var(--glass-border);
    display: flex;
    justify-content: flex-end;
    gap: 15px;
}

@media (max-width: 768px) {
    .profile-header-flex {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .profile-photo-wrapper {
        margin-bottom: 20px;
    }
}

.form-group-unified {
    margin-bottom: 15px;
}

.form-group-unified label {
    display: block;
    color: var(--gold-highlight);
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-input-unified {
    width: 100%;
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--glass-border);
    color: var(--text-main);
    padding: 12px 15px;
    border-radius: 4px;
    font-family: var(--font-family-main);
    font-size: 16px;
    transition: all 0.2s ease;
}

textarea.form-input-unified {
    resize: none;
}

.form-input-unified:focus {
    border-color: var(--gold-primary);
    outline: none;
    background: rgba(0, 0, 0, 0.5);
    box-shadow: 0 0 0 2px rgba(197, 160, 101, 0.2);
}

.btn-unified {
    background: var(--gold-gradient);
    border: none;
    color: #000;
    padding: 12px 30px;
    font-family: var(--font-family-display);
    font-size: 18px;
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-top: 10px;
}

.btn-unified:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(197, 160, 101, 0.4);
}

/* Calendar Tweaks */
.calendar-layout-unified {
    display: flex;
    gap: 30px;
}

.calendar-main {
    flex: 1;
}

.calendar-sidebar {
    width: 300px;
    flex-shrink: 0;
}

@media (max-width: 992px) {
    .calendar-layout-unified {
        flex-direction: column;
    }
    .calendar-sidebar {
        width: 100%;
    }
}

/* =========================
   4. HEM.CSS (CORE)
   ========================= */

body {
  font-family: "Inter", system-ui, sans-serif;
  background-color: var(--bg-main);
  color: var(--text-main);
  min-height: 100vh;
  display: flex;
  position: relative;
  z-index: 0;
  
  /* Kolfiber bakgrund */
  background-image:
    linear-gradient(45deg, rgba(255,255,255,0.015) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.015) 75%, rgba(255,255,255,0.015)),
    linear-gradient(45deg, rgba(255,255,255,0.015) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.015) 75%, rgba(255,255,255,0.015)),
    linear-gradient(to right, rgba(227,157,5,0.05), rgba(227,157,5,0) 50%, rgba(227,157,5,0.05));
  background-size: 12px 12px, 12px 12px, 100% 100%;
  background-position: 0 0, 6px 6px, 0 0;
  /* background-attachment: fixed; - Removed for mobile robustness */
}

/* Glas-effekt över hela sidan */
body::after {
  content: "";
  position: fixed;
  inset: -10%; /* Make it slightly larger to allow transform without showing edges */
  z-index: 1;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  background-image: 
    radial-gradient(circle at 20% 30%, rgba(255,255,255,0.08), transparent 60%),
    radial-gradient(circle at 80% 40%, rgba(255,255,255,0.06), transparent 60%),
    radial-gradient(circle at 50% 70%, rgba(255,255,255,0.05), transparent 70%);
  filter: blur(30px);
  opacity: 0.7;
  animation: glassReflections 40s ease-in-out infinite;
  will-change: transform;
  transform: translateZ(0); /* Force hardware acceleration */
}

#appContent {
  width: 100%;
}

@keyframes glassReflections {
  0% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(2%, 1%) rotate(0.5deg); }
  66% { transform: translate(-1%, 2%) rotate(-0.5deg); }
  100% { transform: translate(0, 0) rotate(0deg); }
}

.dashboard {
  display: flex;
  width: 100%;
  height: 100vh;
  position: relative;
  z-index: 2;
}

.main-content {
  flex: 1;
  padding: 40px;
  overflow-y: auto;
  background-color: transparent;
  position: relative;
  z-index: 2;
}

.content-section {
  display: none;
}

.content-section.active {
  display: block;
}

.content-section h2 {
  font-size: 28px;
  margin-bottom: 16px;
  color: var(--accent);
}

.content-section p {
  font-size: 16px;
  color: var(--text-main);
  line-height: 1.6;
}

#lineup-container {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
}

#field-container {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  position: relative;
  width: 100%;
  max-width: 800px;
}

#lineup-text-right {
  flex: 1;
  min-width: 250px;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text-main);
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  margin-top: 0;
}

#lineup-text-bottom {
  margin-top: 20px;
  font-size: 16px;
  line-height: 1.5;
  color: var(--text-main);
  width: 100%;
}

#field {
  position: relative;
  width: 800px;
  height: 800px;
  background-color: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--glass-border);
  box-shadow: inset 0 0 50px rgba(0,0,0,0.5);
  margin: 0 auto;
  overflow: hidden;
  border-radius: 4px;
}

.cone {
  position: absolute;
  width: 15px;
  height: 15px;
  border: 2px solid var(--accent);
  background-color: transparent;
}

#cone1 { top: calc(var(--cone-margin) + var(--cone-offset-y)); left: var(--cone-margin); }
#cone2 { top: calc(var(--cone-margin) + var(--cone-offset-y)); right: var(--cone-margin); }
#cone3 { bottom: calc(var(--cone-margin) - var(--cone-offset-y)); left: var(--cone-margin); }
#cone4 { bottom: calc(var(--cone-margin) - var(--cone-offset-y)); right: var(--cone-margin); }

.player {
  width: 32px;
  height: 32px;
  font-size: 10px;
  color: var(--white);
  border: 2px solid var(--gold-primary);
  box-shadow: 0 2px 5px rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
  z-index: 10;
  border-radius: 50%;
  pointer-events: auto;
}

.player-name {
  font-family: var(--font-family-display);
  font-weight: 800;
  font-size: 11px;
  color: var(--white);
  background: transparent;
  padding: 0;
  border: none;
  margin-top: 4px;
  position: relative;
  z-index: 10;
  text-align: center;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  text-shadow: -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000, 0 2px 4px rgba(0,0,0,0.8);
  box-shadow: none;
  min-width: auto;
}

.player-tooltip {
  position: absolute;
  background: rgba(0,0,0,0.8);
  color: var(--text-main);
  padding: 6px 10px;
  border-radius: 4px;
  font-size: 12px;
  white-space: nowrap;
  pointer-events: none;
  opacity: 0;
  transition: opacity 0.2s;
  z-index: 1000;
}

.player-wrapper {
  position: absolute;
  width: 0;
  height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: move;
  transition: transform 0.2s ease;
  transform: translate(-50%, -50%);
  z-index: 10;
  pointer-events: none;
  overflow: visible;
}

.player-wrapper.non-admin { cursor: default; }
.player-wrapper:active { cursor: grabbing; }

.player-area {
  border: 2px dashed rgba(227, 157, 5, 0.5);
  border-radius: 50%;
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
  display: none;
  z-index: 5;
  box-sizing: border-box;
}

.canvas-overlay-full {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none;
}

#chainAdminPanel,
#radiusControlPanel,
#heatmapControls {
  display: none;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  transition: box-shadow 0.3s ease;
  resize: both;
  overflow: hidden;
  min-width: 200px;
  min-height: 100px;
}

#chainAdminPanel:hover,
#radiusControlPanel:hover,
#heatmapControls:hover {
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6);
}

.panel-header {
  cursor: move;
  user-select: none;
  -webkit-user-select: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(227, 157, 5, 0.3);
}

.panel-header:active { cursor: grabbing; }
.panel-controls { display: flex; gap: 5px; }

.panel-minimize-btn {
  background: none;
  border: none;
  color: var(--text-muted);
  cursor: pointer;
  font-size: 12px;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.panel-minimize-btn:hover {
  color: var(--gold-primary);
  transform: scale(1.2);
}

.panel-row {
  display: flex;
  gap: 10px;
  align-items: center;
}

.panel-info {
  font-size: 13px;
  color: var(--text-muted);
}

.panel-info span {
  color: var(--gold-primary);
  font-weight: bold;
}

.panel-close-btn {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 85, 85, 0.1);
  color: rgba(255, 85, 85, 0.8);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  transition: all 0.3s ease;
}

.panel-close-btn:hover {
  background: rgba(255, 85, 85, 0.3);
  color: white;
  border-color: rgba(255, 85, 85, 0.5);
}

.panel-minimize-btn:hover { background: rgba(227, 157, 5, 0.2); }
.panel-close-btn:hover { background: rgba(255, 85, 85, 0.2); color: var(--danger); }

.panel-content {
  transition: max-height 0.3s ease, opacity 0.3s ease;
  overflow: hidden;
}

.panel-content.collapsed { max-height: 0; opacity: 0; }

#toggleEdit {
  position: fixed;
  top: 15px;
  right: 15px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 2px solid var(--accent);
  background-color: transparent;
  cursor: pointer;
  z-index: 1000;
  display: none;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, border-color 0.2s ease;
}

#toggleEdit:hover { transform: scale(1.1); border-color: var(--accent-bright); }
#toggleEdit svg { width: 24px; height: 24px; fill: var(--accent); }
#toggleEdit .saveIcon { display: none; }
#toggleEdit.editMode .editIcon { display: none; }
#toggleEdit.editMode .saveIcon { display: block; }

#editorToolbar {
    display: none;
    position: fixed;
    top: 80px;
    right: 20px;
    background: var(--white);
    border: 1px solid var(--border-light);
    padding: 8px;
    border-radius: 6px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    z-index: 1000;
}

#editorToolbar button { border: none; background: none; cursor: pointer; margin: 0 2px; font-size: 16px; }
#editorToolbar input[type=color] { width: 24px; height: 24px; border: none; padding: 0; cursor: pointer; }
.toolbar-buttons { display: flex; gap: 4px; }

.editable { min-height: 20px; }
.editMode .editable { border-bottom: 1px dashed var(--accent); cursor: text; padding: 2px 4px; color: var(--text-main); }
.minimize-icon { display: inline-block; transition: transform 0.3s ease; font-size: 12px; }
.collapsed .minimize-icon { transform: rotate(-90deg); }

button:focus-visible, .field-btn:focus-visible, .btn-primary:focus-visible, .view-btn:focus-visible, .nav-btn:focus-visible, .today-btn:focus-visible, .news-action-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
input:focus-visible, select:focus-visible, textarea:focus-visible { border-color: var(--accent); outline: none; }

#heatmapCanvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; opacity: 0.65; }
#chainCanvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; z-index: 5; }
#chainHoverCanvas { position: absolute; top: 0; left: 0; width: 100%; height: 100%; pointer-events: none; z-index: 6; }
#heatmapClickOverlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 3; cursor: crosshair; pointer-events: auto; }

.heatmap-name-shadow { -webkit-text-stroke: 2px var(--black); paint-order: stroke fill; font-weight: 600 !important; text-shadow: none !important; }
.heatmap-player-shadow { box-shadow: 0 0 0 1px var(--black), 0 0 4px rgba(0,0,0,0.7); }
.heatmap-area-outline { border: 1px solid var(--black) !important; box-shadow: 0 0 4px rgba(0,0,0,0.5); }

.player-dot-small { width: 15px; height: 15px; font-size: 8px; }
.player-dot-square { border-radius: 0 !important; }

.player-area--base { border: 1px solid rgba(150,150,150,0.5); background-color: rgba(150,150,150,0.1); }
.player-area-show { display: block !important; border-color: var(--accent-a-30); background-color: var(--accent-a-05); }
.player-area--selected { border: 2px solid var(--green-neon); background-color: rgba(0,255,0,0.1); }

.player::after { content: ''; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 44px; height: 44px; border-radius: 50%; z-index: -1; pointer-events: auto; }

@media (hover: hover) {
  .player-wrapper:hover .player { box-shadow: 0 0 12px rgba(197, 160, 101, 0.6); border-color: var(--gold-highlight); }
}

.player-selected { box-shadow: 0 0 20px rgba(197, 160, 101, 0.9) !important; border-color: var(--white) !important; z-index: 50 !important; }

.temp-message { position: fixed; top: 20px; right: 20px; color: var(--white); padding: 12px 20px; border-radius: 6px; font-size: 14px; z-index: 10000; box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
.temp-message.success { background: rgba(76, 175, 80, 0.9); }
.temp-message.error { background: rgba(244, 67, 54, 0.9); }
.temp-message.info { background: rgba(0,0,0,0.8); color: var(--accent); }

.fade-out { opacity: 0 !important; transition: opacity 0.5s ease; }
.calendar-week-dates { font-size: 14px; color: #9aa4b2; }

/* =========================
   5. NEWS-CALENDAR.CSS
   ========================= */
.news-container { width: 100%; }
.news-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; width: 100%; }

.news-post {
  border-radius: 4px;
  padding: 25px;
  border: none;
  background: rgba(0, 0, 0, 0.3);
  transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
  width: 100%;
  box-sizing: border-box;
  margin-bottom: 20px;
  box-shadow: none;
  will-change: transform;
}
.news-post:hover { transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2); background: rgba(0, 0, 0, 0.4); }

.news-post-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 15px; padding-bottom: 10px; border-bottom: 1px solid var(--glass-border); }
.news-post-title { font-size: 20px; font-weight: 700; color: var(--accent); margin: 0; }
.news-post-date { font-size: 14px; color: var(--text-muted); margin: 10px; }
.news-post-content { color: var(--text-main); line-height: 1.6; }

.news-post-content * { font-family: var(--font-family-main, "Inter", system-ui, sans-serif) !important; background-color: transparent !important; color: inherit; font-size: inherit; }
.news-post-content h1, .news-post-content h2, .news-post-content h3, .news-post-content h4, .news-post-content h5, .news-post-content h6 { color: var(--accent) !important; margin-top: 20px; margin-bottom: 10px; font-weight: 700 !important; }
.news-post-content h2, .news-post-content h3 { font-size: 1.4em !important; }
.news-post-content p { margin-bottom: 10px; }
.news-post-content ul, .news-post-content ol { margin-left: 20px; margin-bottom: 10px; list-style-position: inside; }

.news-post-actions { display: flex; gap: 10px; margin-top: 15px; padding-top: 15px; border-top: 1px solid var(--accent-a-20); }

.format-btn { padding: 5px 10px; background: rgba(227, 157, 5, 0.2); border: 1px solid rgba(227, 157, 5, 0.3); color: #e39d05; border-radius: 4px; cursor: pointer; font-weight: bold; }
.format-btn:hover { background: rgba(227, 157, 5, 0.3); }
.edit-news-btn { padding: 5px 10px; font-size: 12px; }

.news-editor-container { background: rgba(0,0,0,0.7); padding: 20px; border-radius: 8px; border: 1px solid var(--accent); margin-bottom: 30px; }
.news-editor-title { color: var(--accent); margin-bottom: 15px; }
.news-editor-input { width: 100%; padding: 8px; border-radius: 4px; border: 1px solid var(--border-muted); background: var(--backdrop-dark); color: var(--text-main); margin-bottom: 15px; box-sizing: border-box; }
.news-editor-content { min-height: 200px; border: 1px solid var(--border-muted); background: var(--backdrop-dark); color: var(--text-main); padding: 10px; border-radius: 4px; overflow-y: auto; }

.news-editor-actions { display: flex; gap: 10px; margin-top: 15px; }
.news-action-btn { flex: 1; padding: 8px; border-radius: 4px; cursor: pointer; border: none; }
.news-action-btn-primary { background: var(--accent); color: white; }
.news-action-btn-secondary { background: var(--gray-666); color: var(--text-main); }
.news-action-btn-danger { background: var(--red-500); color: var(--text-main); }
.news-list { display: grid; gap: 20px; margin-top: 20px; }

.schedule-container { width: 100%; padding: 30px; }
.schedule-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 20px; flex-wrap: wrap; gap: 15px; width: 100%; }

.calendar-layout { display: flex; gap: 30px; align-items: flex-start; width: 100%; }
.calendar-main-view { flex: 0 1 auto; width: 100%; max-width: 800px; min-width: 0; }
.upcoming-sidebar { flex: 0 0 300px; background: rgba(0, 0, 0, 0.2); border-radius: 4px; padding: 20px; border: none; }

.sidebar-title { margin-top: 0; margin-bottom: 15px; font-family: var(--font-family-display); text-transform: uppercase; color: var(--gold-primary); font-size: 24px; }

.calendar-controls { display: flex; justify-content: space-between; align-items: center; padding: 10px 15px; border-radius: 4px; margin-bottom: 20px; border: 1px solid var(--glass-border); background: rgba(0,0,0,0.2); max-width: 800px; width: 100%; box-sizing: border-box; transition: transform 0.2s ease, box-shadow 0.2s ease; }
.date-navigation { display: flex; align-items: center; gap: 15px; flex: 1; justify-content: center; }
.current-date-display { text-align: center; color: var(--text-main); min-width: 250px; font-size: 16px; padding: 0 20px; }

.nav-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--text-muted);
  width: 36px;
  height: 36px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
}
.nav-btn:hover { background: rgba(255, 255, 255, 0.05); border-color: var(--gold-primary); color: var(--gold-primary); transform: translateY(-2px); box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2); }
.nav-btn svg { width: 20px; height: 20px; }

.today-btn {
  background: var(--accent-a-30);
  border: 1px solid var(--accent-a-50);
  color: var(--text-main);
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.2s ease, background-color 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
  font-size: 14px;
}
.today-btn:hover { background: var(--gold-primary); color: var(--black); transform: translateY(-2px); box-shadow: 0 5px 15px rgba(197, 160, 101, 0.4); }

.calendar-container { border-radius: 4px; border: none; overflow: hidden; width: 100%; max-width: 800px; height: 60vh; min-height: 400px; display: flex; flex-direction: column; transition: box-shadow 0.2s ease; background: rgba(0,0,0,0.2); margin-top: 20px; }
.calendar-container:hover { box-shadow: none; }
.calendar-content { flex: 1; overflow: hidden; position: relative; }
.calendar-wrapper { display: flex; flex-direction: column; height: 100%; overflow: hidden; position: relative; }
.calendar-scroll-area { overflow: auto; height: 100%; position: relative; border-radius: 8px; }

.calendar-header-row, .calendar-body-grid { display: grid; grid-template-columns: 60px repeat(7, 1fr); width: 100%; }
.calendar-header-row { position: sticky; top: 0; z-index: 20; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--accent-a-20); }

.calendar-time-header { background: transparent; padding: 0 10px; height: 40px; display: flex; align-items: center; justify-content: center; color: var(--accent); font-size: 12px; font-weight: bold; box-sizing: border-box; border-right: 1px solid var(--accent-a-20); position: sticky; left: 0; top: 0; z-index: 30; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.calendar-day-header { background: transparent; padding: 0 10px; height: 40px; display: flex; flex-direction: column; align-items: center; justify-content: center; color: var(--white); font-size: 12px; font-weight: bold; box-sizing: border-box; border-right: 1px solid var(--accent-a-10); }
.calendar-day-header.today { color: var(--accent); }
.calendar-day-header .day-name { font-size: 11px; color: var(--text-muted); }
.calendar-day-header .day-date { font-size: 16px; }

.calendar-time-slot-label { padding: 5px 10px; color: var(--text-muted); font-size: 11px; border-right: 1px solid var(--accent-a-20); border-bottom: 1px solid var(--accent-a-10); min-height: 60px; position: sticky; left: 0; z-index: 10; backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }
.calendar-time-slot { background: transparent; min-height: 60px; border-bottom: 1px solid var(--accent-a-10); border-right: 1px solid var(--accent-a-10); position: relative; cursor: default; overflow: visible; padding: 0; }
.calendar-header-grid { display: none; }

@media (max-width: 992px) {
  .calendar-header-row, .calendar-body-grid { min-width: 600px; }
}

.calendar-time-slot.interactive { cursor: pointer; }

.calendar-event-base { position: absolute; left: 2px; right: 2px; color: white; border-radius: 4px; padding: 4px 6px; overflow: hidden; z-index: 2; cursor: pointer; box-shadow: 0 2px 4px rgba(0,0,0,0.2); transition: transform 0.2s, box-shadow 0.2s; }
.calendar-event-title { font-size: 11px; font-weight: bold; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.calendar-event-time { font-size: 10px; opacity: 0.9; }

.event-type-training { background-color: #4CAF50; border-left: 3px solid #388E3C; }
.event-type-match { background-color: #f44336; border-left: 3px solid #D32F2F; }
.event-type-meeting { background-color: #2196F3; border-left: 3px solid #1976D2; }
.event-type-other { background-color: #9C27B0; border-left: 3px solid #7B1FA2; }

.upcoming-list-empty { color: var(--text-muted); font-size: 14px; text-align: center; padding: 20px; }
.upcoming-event-card { padding: 12px; border-radius: 6px; cursor: pointer; transition: background 0.2s; margin-bottom: 8px; border: 2px solid transparent; }
.upcoming-event-card:hover { background: rgba(255,255,255,0.1); }
.upcoming-event-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 5px; }
.upcoming-event-title { font-weight: bold; color: white; font-size: 14px; }
.upcoming-event-pill { font-size: 11px; color: white; padding: 2px 6px; border-radius: 10px; }
.upcoming-event-meta { color: var(--text-muted); font-size: 12px; margin-bottom: 3px; }
.upcoming-event-location { color: var(--accent); font-size: 11px; }
.upcoming-event-description { color: #ccc; font-size: 12px; margin-top: 5px; display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.event-pill-training { background-color: #4CAF50; }
.event-pill-match { background-color: #f44336; }
.event-pill-meeting { background-color: #2196F3; }
.event-pill-other { background-color: #9C27B0; }
.event-card-training { border-color: #4CAF50 !important; }
.event-card-match { border-color: #f44336 !important; }
.event-card-meeting { border-color: #2196F3 !important; }
.event-card-other { border-color: #9C27B0 !important; }

#eventEditor { margin-top: 30px; background: rgba(0, 0, 0, 0.8); padding: 25px; border-radius: 8px; border: 1px solid var(--accent); width: 100%; box-sizing: border-box; }
#eventEditor h3 { color: var(--accent); margin-bottom: 20px; font-size: 20px; }
#eventEditor input, #eventEditor select, #eventEditor textarea { width: 100%; padding: 10px; border-radius: 4px; border: 1px solid var(--border-muted); background: var(--backdrop-dark); color: var(--text-main); margin-bottom: 15px; font-size: 14px; box-sizing: border-box; }
#eventEditor textarea { min-height: 100px; resize: vertical; }

.event-info-modal { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 10000; pointer-events: auto; width: 90%; max-width: 450px; }
.event-info-content { background: rgba(0,0,0,0.9); border-radius: 8px; border: 1px solid var(--accent); max-width: 400px; margin: 0 auto; padding: 20px; }
.event-info-title { color: var(--accent); margin-bottom: 10px; font-size: 18px; }
.event-info-row { color: #fff; margin-bottom: 5px; font-size: 14px; }
.event-info-desc { color: #ccc; margin-top: 10px; font-size: 14px; line-height: 1.5; }
.event-info-details { margin-bottom: 15px; }
.event-info-close-btn { background: var(--accent); color: white; border: none; padding: 8px 16px; border-radius: 4px; cursor: pointer; font-size: 14px; margin-top: 15px; transition: background-color 0.2s; }
.event-info-close-btn:hover { filter: brightness(0.9); }
.event-info-overlay { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.7); z-index: 9999; cursor: pointer; }

/* Scrollbar styling */
.calendar-container::-webkit-scrollbar, .calendar-week-grid::-webkit-scrollbar { width: 8px; height: 8px; }
.calendar-container::-webkit-scrollbar-track, .calendar-week-grid::-webkit-scrollbar-track { background: var(--white-a-05); border-radius: 4px; }
.calendar-container::-webkit-scrollbar-thumb, .calendar-week-grid::-webkit-scrollbar-thumb { background: var(--accent-a-30); border-radius: 4px; }
.calendar-container::-webkit-scrollbar-thumb:hover, .calendar-week-grid::-webkit-scrollbar-thumb:hover { background: var(--accent-a-50); }

/* =========================
   6. ADMIN-STYLES.CSS
   ========================= */
#playerAdminPanel { display: none; }
.admin-panel { display: none; margin-top: 10px; gap: 8px; align-items: center; flex-wrap: wrap; }
#radiusControlPanel { position: fixed; bottom: 20px; right: 20px; background: rgba(0,0,0,0.95); color: var(--text-main); padding: 15px; border-radius: 8px; z-index: 1001; width: 280px; display: none; border: 1px solid var(--accent); box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
#chainAdminPanel { position: fixed; bottom: 80px; left: 20px; background: rgba(0,0,0,0.95); color: var(--text-main); padding: 20px; border-radius: 8px; z-index: 1002; width: 320px; max-height: 80vh; overflow-y: auto; border: 2px solid var(--green-neon); display: none; box-shadow: 0 4px 12px rgba(0,0,0,0.3); }
#heatmapControls { position: absolute; top: 50px; left: 10px; z-index: 1000; display: none; background: rgba(0,0,0,0.8); padding: 10px; border-radius: 6px; border: 1px solid var(--accent); width: 180px; }
#heatmapIntensityValue { color: var(--text-main); font-size: 12px; }

#field-controls { position: absolute; top: 10px; left: 10px; z-index: 1000; display: flex; gap: 8px; }
.field-btn { width: 32px; height: 32px; border-radius: 50%; border: 1px solid rgba(227, 157, 5, 0.3); background: rgba(0, 0, 0, 0.7); color: var(--accent); cursor: pointer; display: flex; align-items: center; justify-content: center; transition: all 0.2s ease; }
.field-btn:hover { background: rgba(227, 157, 5, 0.2); transform: scale(1.1); }
.field-btn.active { background: rgba(227, 157, 5, 0.3); color: #fff; border-color: var(--accent); }

.panel-content.collapsed { max-height: 0; opacity: 0; }
#newsAdminControls, #scheduleAdminControls { display: none; }
.btn-primary { background-color: var(--accent); color: #fff; border: none; padding: 8px 16px; border-radius: 4px; cursor: pointer; font-weight: 600; transition: background-color 0.2s; }
.btn-primary:hover { background-color: var(--accent-bright); }
#profileMsg { margin-top: 10px; color: green; }

/* =========================
   7. COMPONENTS/EDITOR.CSS
   ========================= */
.editor-modal { background: rgba(0,0,0,0.7); padding: 20px; border-radius: 8px; border: 1px solid var(--accent); }
.editor-title { color: var(--accent); margin-bottom: 15px; }
.form-label { display: block; margin-bottom: 5px; color: var(--text-main); }
.input-dark { width: 100%; padding: 8px; border-radius: var(--radius-sm); border: 1px solid var(--border-muted); background: var(--backdrop-dark); color: var(--text-main); }
.input-dark, input, select, textarea, button { font-family: var(--font-family-main, "Inter", system-ui, sans-serif); }

.editor-content { min-height: 200px; border: 1px solid var(--border-muted); background: var(--backdrop-dark); color: var(--text-main); padding: 10px; border-radius: var(--radius-sm); overflow-y: auto; font-family: var(--font-family-main, 'Inter', sans-serif); font-size: 16px; line-height: 1.5; }
.editor-content * { font-family: var(--font-family-main, 'Inter', sans-serif) !important; background-color: transparent !important; color: inherit; font-size: inherit; }
.editor-content h1, .editor-content h2, .editor-content h3, .editor-content h4, .editor-content h5, .editor-content h6 { color: var(--accent) !important; font-weight: bold !important; }
.editor-content ul, .editor-content ol { margin-left: 20px; list-style-position: inside; }
.editor-content h2, .editor-content h3 { color: var(--accent); margin-top: 15px; margin-bottom: 8px; font-size: 1.25em; border-bottom: 1px solid var(--accent-a-20); padding-bottom: 4px; }
.btn-secondary { background: var(--gray-666); color: var(--white); border: none; padding: 8px; border-radius: var(--radius-sm); cursor: pointer; }
.btn-danger { background: #f44336; color: var(--white); border: none; padding: 8px; border-radius: var(--radius-sm); cursor: pointer; }

/* =========================
   8. NHL-DASHBOARD.CSS
   ========================= */

.main-header { 
   position: fixed; 
   top: 0; 
   left: 0; 
   width: 100%; 
   height: 80px; 
   background: rgba(10, 12, 16, 0.95); 
   backdrop-filter: blur(12px); 
   border-bottom: 1px solid var(--glass-border); 
   display: grid;
   grid-template-columns: 1fr auto 1fr;
   align-items: center; 
   padding: 0 40px; 
   z-index: 1100; 
   box-shadow: 0 4px 20px rgba(0,0,0,0.4); 
 }

 .main-content { padding-top: 100px !important; min-height: 100vh; box-sizing: border-box; }

 .header-logo { height: 50px; display: flex; align-items: center; gap: 15px; cursor: pointer; justify-self: start; }
 .header-logo img { height: 100%; width: auto; filter: drop-shadow(0 0 10px rgba(198, 156, 109, 0.3)); }
 .header-logo span { font-family: var(--font-family-display); font-size: 24px; font-weight: 800; text-transform: uppercase; letter-spacing: 1px; background: var(--gold-gradient); -webkit-background-clip: text; background-clip: text; color: transparent; }

 .header-logo #introVideoBtn {
   width: 36px;
   height: 36px;
   padding: 0;
   background: rgba(10, 12, 16, 0.6);
   border: 1px solid rgba(227, 157, 5, 0.4);
   border-radius: 4px;
   color: var(--gold-primary);
   cursor: pointer;
   display: flex;
   align-items: center;
   justify-content: center;
   transition: all 0.3s ease;
   position: relative;
   overflow: hidden;
   flex-shrink: 0;
   box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
 }
 .header-logo #introVideoBtn:hover { background: rgba(227, 157, 5, 0.15); border-color: var(--gold-primary); color: var(--gold-highlight); transform: translateY(-2px); }
 .header-logo #introVideoBtn svg { width: 16px; height: 16px; fill: currentColor; }

 .nav-home {
   display: flex;
   align-items: center;
   justify-content: center;
   width: 48px;
   height: 48px;
   border-radius: 4px;
   background: transparent;
   border: none;
   transition: all 0.3s ease;
   color: var(--text-muted);
 }
 .nav-home svg { width: 28px; height: 28px; fill: currentColor; }
 .nav-home:hover, .nav-home.active { color: var(--gold-primary); transform: scale(1.1); }

 .header-nav { 
   display: flex; 
   align-items: center; 
   gap: 0; 
 }
.nav-group { display: flex; gap: 30px; width: 200px; }
.nav-group.left { justify-content: flex-end; margin-right: 30px; }
.nav-group.right { justify-content: flex-start; margin-left: 30px; }

.nav-link { 
    color: var(--text-muted); 
    text-decoration: none; 
    font-weight: 600; 
    text-transform: uppercase; 
    font-size: 14px; 
    letter-spacing: 1px; 
    transition: all 0.3s ease; 
    padding: 8px 0; 
    position: relative; 
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.nav-icon {
    width: 20px;
    height: 20px;
    display: none; /* Hide on desktop by default, or show if you want */
}
.nav-link::after { content: ''; position: absolute; bottom: 0; left: 0; width: 0; height: 2px; background: var(--gold-gradient); transition: width 0.3s ease; }
.nav-link:hover, .nav-link.active { color: var(--white); }
.nav-link:hover::after, .nav-link.active::after { width: 100%; }

.header-user { display: flex; align-items: center; gap: 15px; justify-self: end; }
#logoutBtnHeader { padding: 8px 20px; font-size: 13px; font-weight: 700; font-family: var(--font-family-main); text-transform: uppercase; letter-spacing: 1px; background: transparent; border: 1px solid var(--gold-primary); color: var(--gold-primary); border-radius: 4px; cursor: pointer; transition: all 0.3s ease; }
#logoutBtnHeader:hover { background: var(--gold-primary); color: var(--black); box-shadow: 0 0 15px rgba(197, 160, 101, 0.4); transform: translateY(-1px); }

#videoOverlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: #000; z-index: 2000; display: none; align-items: center; justify-content: center; overflow: hidden; }
#videoOverlay.active { display: flex; }
#videoOverlay video { width: 100%; height: 100%; object-fit: contain; background: #000; outline: none; appearance: none; -webkit-appearance: none; }
#videoOverlay video::-webkit-media-controls { display: none !important; }
#videoOverlay video::-webkit-media-controls-enclosure { display: none !important; }

#dashboard-home { min-height: calc(100vh - 100px); height: auto; display: flex; flex-direction: column; justify-content: center; align-items: center; }
.dashboard-grid { 
  display: grid; 
  grid-template-columns: repeat(4, 1fr); 
  grid-template-rows: auto; 
  gap: 20px; 
  width: 100%; 
  max-width: 100%; 
  padding: 0 20px; 
}
.dashboard-tile.featured { grid-column: span 1; }

.dashboard-tile {
  background: var(--bg-secondary);
  border: 1px solid var(--glass-border);
  border-radius: var(--panel-radius);
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: all 0.5s cubic-bezier(0.25, 0.8, 0.25, 1);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: var(--space-xl);
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
  will-change: transform, opacity, box-shadow;
  transform: translateZ(0);
  z-index: 10;
  min-height: 380px;
}
.dashboard-tile::before { content: ''; position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,0.9), transparent); z-index: 1; }
@media (hover: hover) {
  .dashboard-tile:not(.hero-active):hover { transform: translateY(-5px); border-color: var(--gold-primary); box-shadow: 0 20px 50px rgba(255, 215, 0, 0.15); }
  .dashboard-tile:not(.hero-active):hover .tile-bg { opacity: 0.8; }
}

.tile-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
  transition: all 0.5s ease;
  z-index: 0;
  opacity: 0.6;
  will-change: opacity, filter;
}

.tile-archive .tile-bg { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffffff' opacity='0.1'%3E%3Cpath d='M19 3h-4.18C14.4 1.84 13.3 1 12 1c-1.3 0-2.4.84-2.82 2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm-7 0c.55 0 1 .45 1 1s-.45 1-1 1-1-.45-1-1 .45-1 1-1zm2 14H7v-2h7v2zm3-4H7v-2h10v2zm0-4H7V7h10v2z'/%3E%3C/svg%3E") no-repeat center center, linear-gradient(135deg, #2a2a2a, #1a1a1a); background-size: 50% auto, cover; opacity: 1; }
.tile-news .tile-bg { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffffff' opacity='0.1'%3E%3Cpath d='M20 2H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h14l4 4V4c0-1.1-.9-2-2-2zm-2 12H6v-2h12v2zm0-3H6V9h12v2zm0-3H6V6h12v2z'/%3E%3C/svg%3E") no-repeat center center, linear-gradient(135deg, #0f2027, #203a43, #2c5364); background-size: 50% auto, cover; opacity: 1; }
.tile-schedule .tile-bg { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffffff' opacity='0.1'%3E%3Cpath d='M19 3h-1V1h-2v2H8V1H6v2H5c-1.11 0-2 .9-2 2v14c0 1.1.89 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm0 16H5V8h14v11zM7 10h5v5H7z'/%3E%3C/svg%3E") no-repeat center center, linear-gradient(135deg, #414345, #232526); background-size: 50% auto, cover; opacity: 1; }
.tile-profile .tile-bg { background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23ffffff' opacity='0.1'%3E%3Cpath d='M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 3c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm0 14.2c-2.5 0-4.71-1.28-6-3.22.03-1.99 4-3.08 6-3.08 1.99 0 5.97 1.09 6 3.08-1.29 1.94-3.5 3.22-6 3.22z'/%3E%3C/svg%3E") no-repeat center center, linear-gradient(135deg, #141E30, #243B55); background-size: 50% auto, cover; opacity: 1; }

.tile-content { 
  position: relative; 
  z-index: 2; 
  transform: translateY(0); 
  transition: transform 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  height: 100%;
  width: 100%;
}
.tile-subtitle { font-size: 14px; text-transform: uppercase; letter-spacing: 2px; color: var(--gold-highlight); margin-bottom: 8px; font-weight: 700; }
.tile-title { 
  font-family: var(--font-family-display); 
  font-size: clamp(1.8rem, 4vw, 2.2rem); 
  text-transform: uppercase; 
  font-weight: 900; 
  color: var(--white); 
  line-height: 1.1; 
  margin-bottom: 10px; 
}
.tile-description { color: var(--text-muted); font-size: 16px; opacity: 0; transform: translateY(20px); transition: all 0.3s ease; max-height: 0; }

@media (hover: hover) {
  .dashboard-tile:not(.hero-active):hover .tile-description { opacity: 1; transform: translateY(0); max-height: 100px; }
}

.dashboard-tile.hero-active .tile-bg {
  opacity: 1;
  filter: blur(8px);
  inset: -50px;
  width: calc(100% + 100px);
  height: calc(100% + 100px);
}
.tile-archive.hero-active .tile-bg { background: linear-gradient(135deg, #2a2a2a, #1a1a1a) !important; }
.tile-news.hero-active .tile-bg { background: linear-gradient(135deg, #0f2027, #203a43, #2c5364) !important; }
.tile-schedule.hero-active .tile-bg { background: linear-gradient(135deg, #414345, #232526) !important; }
.tile-profile.hero-active .tile-bg { background: linear-gradient(135deg, #141E30, #243B55) !important; }
.content-section:not(.active) { display: none !important; }

@media (max-width: 1024px) {
  .dashboard-grid { grid-template-columns: repeat(2, 1fr); grid-template-rows: auto; gap: 15px; }
  .dashboard-tile { min-height: 280px; }
}

@media (max-width: 768px) {
  .dashboard-grid { grid-template-columns: 1fr; grid-template-rows: auto; padding: 0 15px; gap: 12px; }
  .dashboard-tile { min-height: 220px; }
}

/* =========================
   9. HERO-ANIMATION.CSS
   ========================= */
.dashboard-tile.no-transition { transition: none !important; }

.dashboard-tile.hero-active {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  width: 100dvw;
  height: 100vh;
  height: 100dvh;
  z-index: 2000; /* Mycket högre z-index */
  border-radius: 0;
  border: none;
  padding: 0;
  cursor: default;
  box-shadow: none;
  background: var(--bg-main);
  overscroll-behavior: none;
}
.dashboard-tile.hero-active .tile-content {
  max-width: 100%;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-start;
  padding: 0;
  transform: none !important;
}
.dashboard-tile.hero-active .tile-title { display: none; }
.dashboard-tile.hero-active .tile-subtitle { display: none; }
.dashboard-tile.hero-active .tile-description { display: none; }
  
  .hero-content-container {
  visibility: hidden;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s cubic-bezier(0.2, 0.8, 0.2, 1), transform 0.7s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0.7s;
  transition-delay: 0.35s;
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1001;
  padding: 40px;
  padding-top: 120px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior-y: contain;
  /* background removed */
  scrollbar-width: thin;
  scrollbar-color: var(--accent) rgba(0,0,0,0.3);
  will-change: opacity, transform;
}
.hero-content-container::-webkit-scrollbar { width: 6px; }
.hero-content-container::-webkit-scrollbar-track { background: rgba(0,0,0,0.3); }
.hero-content-container::-webkit-scrollbar-thumb { background-color: var(--accent); border-radius: 3px; }

.hero-active .hero-content-container { visibility: visible; opacity: 1; transform: translateY(0); pointer-events: auto; }
body.hero-expanding {
  overflow: hidden;
  overscroll-behavior: none;
  position: fixed;
  width: 100%;
}
body.hero-expanding .dashboard-tile:not(.hero-active) { opacity: 0; pointer-events: none; transform: scale(0.9); }

@media (max-width: 768px) {
    .dashboard-tile.hero-active { top: 0; bottom: 0; height: 100vh; height: 100dvh; border-bottom: none; }
    .dashboard-tile.hero-active .tile-content { padding: 0; }
    .hero-content-container { padding: 20px; padding-top: 80px; padding-bottom: 100px; }
    .dashboard-tile.hero-active .tile-title { display: none; }
}

/* =========================
   10. RESPONSIVE.CSS
   ========================= */
@media (max-width: 992px) {
  .dashboard { flex-direction: column; height: auto; min-height: 100vh; margin-bottom: 100px; }
  .main-content {
    padding: 20px;
    width: 100%;
    overflow-x: hidden !important;
    overflow-y: visible !important;
    max-width: 100vw;
    box-sizing: border-box;
    flex: 1;
    display: block;
    height: auto !important;
  }
  .dashboard {
    flex-direction: column;
    height: auto !important;
    min-height: 100vh;
    min-height: 100dvh;
    overflow-x: hidden !important;
    overflow-y: visible !important;
  }
  html, body {
    overflow-x: hidden;
    overflow-y: auto;
    height: auto;
    min-height: 100vh;
    min-height: 100dvh;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-y: none;
  }

  #field-container { width: 100%; max-width: 100%; align-items: center; overflow-x: hidden; }
  #field { width: 100%; max-width: 600px; height: auto; aspect-ratio: 1 / 1; margin: 0 auto; }
  
  :root {
     --cone-margin: 31.25%;
     --cone-offset-y: 12.5%;
  }

  #cone1 { left: var(--cone-margin); top: calc(var(--cone-margin) + var(--cone-offset-y)); }
  #cone2 { right: var(--cone-margin); top: calc(var(--cone-margin) + var(--cone-offset-y)); }
  #cone3 { left: var(--cone-margin); bottom: calc(var(--cone-margin) - var(--cone-offset-y)); }
  #cone4 { right: var(--cone-margin); bottom: calc(var(--cone-margin) - var(--cone-offset-y)); }
  
  #lineup-container { flex-direction: column; }
  #lineup-text-right { margin-top: 20px; width: 100%; }
  #profileForm { max-width: 100%; }
  .calendar-main-view { display: none; }
  .upcoming-sidebar { flex: 1 1 auto; width: 100%; }
  .upcoming-sidebar .sidebar-title { display: none; }

  #dashboard-home { height: auto !important; min-height: auto; display: block; padding-bottom: 20px; }
}

@media (max-width: 768px) {
  .main-header { top: auto; bottom: 0; height: 60px; padding: 0 10px; grid-template-columns: 1fr; background: rgba(10, 12, 16, 0.95); border-top: 1px solid var(--glass-border); border-bottom: none; box-shadow: 0 -4px 20px rgba(0,0,0,0.4); }
  .header-logo, .header-user { display: none; }
  .header-nav { width: 100%; justify-content: space-between; gap: 0; padding: 0 10px; box-sizing: border-box; position: static; transform: none; }
  .nav-group { width: auto; gap: 0; flex: 1; justify-content: space-around; margin: 0 !important; }
  .nav-link { font-size: 10px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 5px; flex: 1; gap: 2px; }
  .nav-icon { display: block; width: 24px; height: 24px; margin-bottom: 2px; }
  .nav-home { width: 40px; height: 40px; margin: 0 5px; }
  .nav-home svg { width: 24px; height: 24px; }
  .main-content { padding-top: 20px !important; padding-bottom: 20px !important; margin-bottom: 0 !important; }
  .hero-content-container { padding-bottom: calc(140px + env(safe-area-inset-bottom)) !important; }
  .main-content::after { display: none !important; }
  .content-section { padding-bottom: 20px !important; }
  .content-section.active { padding-bottom: 0 !important; margin-bottom: 0 !important; }
  #toggleEdit { top: 20px; right: 20px; }
  .news-container { width: 100%; overflow-x: hidden; }
  .news-list { display: flex; flex-direction: column; width: 100%; margin-right: 0; margin-left: 0; padding-right: 0; padding-left: 0; }
  .news-post { width: 100% !important; max-width: 100% !important; margin-right: 0 !important; margin-left: 0 !important; box-sizing: border-box; }
  .news-post-content { overflow-wrap: break-word; word-wrap: break-word; word-break: break-word; hyphens: auto; }
  .news-post-content img { max-width: 100%; height: auto; }
  .news-post-content a { word-break: break-all; overflow-wrap: break-word; }
}

/* =========================
   12. ADMIN & EDIT MODE
   ========================= */
#toggleEdit {
  position: fixed;
  bottom: 80px;
  right: 20px;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--bg-secondary);
  border: 1px solid var(--glass-border);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 3000;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0,0,0,0.5);
}

#toggleEdit.editMode {
  background: var(--accent);
  color: black;
  transform: scale(1.1);
  box-shadow: 0 0 20px var(--accent-a-30);
}

#editorToolbar {
  position: fixed;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(10, 10, 10, 0.95);
  border: 1px solid var(--accent);
  padding: 5px 15px;
  border-radius: 30px;
  z-index: 3001;
  display: flex;
  gap: 10px;
  align-items: center;
  box-shadow: 0 5px 25px rgba(0,0,0,0.6);
}

.admin-panel {
  position: fixed;
  background: rgba(10, 12, 16, 0.95) !important;
  border: 1px solid var(--gold-primary) !important;
  backdrop-filter: blur(15px);
  box-shadow: 0 15px 50px rgba(0,0,0,0.8) !important;
  border-radius: 8px;
  z-index: 3000;
  width: 280px;
  max-width: 90vw;
  max-height: 85vh;
  display: none;
  flex-direction: column;
  overflow: hidden;
}

.panel-header {
  background: linear-gradient(to right, rgba(197, 160, 101, 0.15), transparent) !important;
  border-bottom: 1px solid rgba(197, 160, 101, 0.2);
  padding: 12px 15px !important;
  cursor: move;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.panel-header span, .panel-header h4 {
  font-family: var(--font-family-display);
  font-size: 16px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 800;
  color: var(--gold-primary);
  margin: 0;
}

.panel-content {
  padding: 15px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
  max-height: calc(85vh - 50px);
}

#chainList, #chainPlayersList {
  max-height: 180px;
  overflow-y: auto;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 4px;
  margin-bottom: 10px;
  scrollbar-width: thin;
}

.admin-panel input[type="text"],
.admin-panel input[type="number"],
.admin-panel select {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: var(--white);
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 13px;
  width: 100%;
  transition: all 0.3s ease;
}

.admin-panel input:focus,
.admin-panel select:focus {
  border-color: var(--gold-primary);
  outline: none;
  background: rgba(0, 0, 0, 0.5);
}

.admin-panel button {
  background: var(--gold-gradient);
  color: var(--black);
  border: none;
  padding: 10px;
  border-radius: 4px;
  font-weight: 800;
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 1px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.admin-panel button:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(197, 160, 101, 0.3);
}

.admin-panel button.btn-secondary {
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
}

.admin-panel button.btn-danger {
  background: rgba(217, 48, 37, 0.8);
  color: var(--white);
}

.panel-close-btn {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: background 0.2s;
}

.panel-close-btn:hover {
  background: rgba(255, 0, 0, 0.2);
}

/* Admin User List */
.admin-user-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--glass-border);
  padding: 15px;
  border-radius: 4px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
  transition: all 0.3s ease;
}

.super-admin-card {
  border-color: var(--gold-primary);
  background: rgba(197, 160, 101, 0.05);
}

.badge {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 20px;
  font-weight: 800;
  margin-left: 8px;
}

.badge-super {
  background: var(--gold-primary);
  color: var(--black);
}

.admin-user-name {
  font-weight: 700;
  font-size: 16px;
  display: flex;
  align-items: center;
}

.admin-user-email {
  font-size: 12px;
  color: var(--text-muted);
}

.admin-user-actions {
  display: flex;
  gap: 15px;
}

.admin-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-size: 13px;
}

.admin-toggle.disabled {
    opacity: 0.5;
    cursor: not-allowed;
  }
  
  /* Mobile Admin Adjustments */
  @media (max-width: 768px) {
    #editorToolbar {
    width: 95%;
    padding: 5px;
    justify-content: center;
    flex-wrap: wrap;
    border-radius: 10px;
    top: 5px;
  }
  
  #editorToolbar button {
    padding: 8px;
    min-width: 35px;
  }

  .admin-panel {
    width: 95% !important;
    left: 2.5% !important;
    right: 2.5% !important;
    max-height: 50vh;
    overflow-y: auto;
  }
  
  #radiusControlPanel {
    bottom: 140px !important;
    top: auto !important;
  }
  
  #chainAdminPanel {
    top: 60px !important;
  }
  
  #toggleEdit {
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
  }
}

.editable:focus {
  outline: none;
  background: rgba(227, 157, 5, 0.05);
  border-radius: 4px;
}
  .landing-page { align-items: center; justify-content: center; padding: 20px; height: 100vh; overflow: hidden; position: fixed; top: 0; left: 0; width: 100%; }
  .login-panel {
    padding: 24px;
    gap: 20px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    overscroll-behavior: contain;
    z-index: 10;
  .brand-title { font-size: 28px; }
  .brand-logo { width: 100px; }
}

/* Säkerställ att texten ALLTID hamnar i botten när tilen inte är expanderad */
.dashboard-tile:not(.hero-active) .tile-content {
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-end !important;
    height: 100% !important;
}

/* ============================================
   CUSTOM SCROLLBARS (Replaces no-scrollbars.css)
   ============================================ */

/* WebKit browsers (Chrome, Safari, Edge) */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
  background: var(--bg-secondary);
}

::-webkit-scrollbar-track {
  background: var(--bg-secondary);
  border-left: 1px solid var(--glass-border);
}

::-webkit-scrollbar-thumb {
  background: var(--accent-a-30);
  border-radius: 4px;
  border: 1px solid var(--bg-main);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gold-primary);
}

/* Firefox */
* {
  scrollbar-width: thin;
  scrollbar-color: var(--accent-a-30) var(--bg-secondary);
}

/* =========================
   11. STYLE.CSS (LANDING & GLOBAL)
   ========================= */
/* =========================
   GLOBAL RESET & VARIABLES
   ========================= */



/* =========================
   BODY & BACKGROUND EFFECTS
   ========================= */
body {
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-family-main);
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

/* Arena Atmosphere Background */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -10;
  background: 
    radial-gradient(circle at 50% 0%, #1a202c 0%, var(--bg-main) 70%),
    radial-gradient(circle at 85% 30%, rgba(198, 156, 109, 0.08), transparent 50%),
    radial-gradient(circle at 15% 80%, rgba(198, 156, 109, 0.05), transparent 50%);
  background-blend-mode: screen;
}

/* Subtle Noise Texture for Realism */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -9;
  opacity: 0.03;
  pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

/* =========================
   LANDING PAGE (CLEAN NHL STYLE)
   ========================= */
.landing-page {
  position: relative;
  width: 100%;
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 20px;
}

/* --- Clean Background --- */
.landing-background {
  position: absolute;
  inset: 0;
  z-index: 0;
  /* Kolfiber bakgrund - Exakt kopia av body i hem.css */
  background-color: var(--bg-main);
  background-image:
    linear-gradient(45deg, rgba(255,255,255,0.015) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.015) 75%, rgba(255,255,255,0.015)),
    linear-gradient(45deg, rgba(255,255,255,0.015) 25%, transparent 25%, transparent 75%, rgba(255,255,255,0.015) 75%, rgba(255,255,255,0.015)),
    linear-gradient(to right, rgba(227,157,5,0.05), rgba(227,157,5,0) 50%, rgba(227,157,5,0.05));
  background-size: 12px 12px, 12px 12px, 100% 100%;
  background-position: 0 0, 6px 6px, 0 0;
  /* background-attachment: fixed; - Removed for mobile robustness */
}

/* Glas-effekt overlay (Exakt kopia av body::after i hem.css) */
.landing-background::after {
  content: "";
  position: absolute;
  inset: -10%;
  pointer-events: none;
  background: rgba(255, 255, 255, 0.02);
  backdrop-filter: blur(12px) saturate(1.2);
  -webkit-backdrop-filter: blur(12px) saturate(1.2);
  background-image: 
    radial-gradient(circle at 20% 30%, rgba(255,255,255,0.08), transparent 60%),
    radial-gradient(circle at 80% 40%, rgba(255,255,255,0.06), transparent 60%),
    radial-gradient(circle at 50% 70%, rgba(255,255,255,0.05), transparent 70%);
  filter: blur(30px);
  opacity: 0.7;
  animation: glassReflections 40s ease-in-out infinite;
  will-change: transform;
  transform: translateZ(0);
}

/* Animationen från hem.css */
@keyframes glassReflections {
  0% { transform: translate(0, 0) rotate(0deg); }
  33% { transform: translate(2%, 1%) rotate(0.5deg); }
  66% { transform: translate(-1%, 2%) rotate(-0.5deg); }
  100% { transform: translate(0, 0) rotate(0deg); }
}

/* --- Content Wrapper --- */
.landing-content {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 400px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

/* --- Login Panel (Matches App Panels) --- */
.login-panel {
  background: linear-gradient(135deg, rgba(20, 20, 20, 0.95), rgba(10, 10, 10, 0.98));
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 4px; /* Sharp corners */
  padding: 40px;
  box-shadow: 
    0 20px 50px rgba(0, 0, 0, 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Brand Section */
.panel-brand {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.brand-logo {
  width: 140px;
  height: auto;
  filter: drop-shadow(0 4px 10px rgba(0,0,0,0.3));
}

.brand-title {
  font-family: var(--font-family-display);
  font-size: 32px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1px;
  background: var(--gold-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  margin: 0;
  line-height: 1;
  text-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.brand-subtitle {
  font-size: 14px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 2px;
  font-weight: 500;
}

/* Divider */
.panel-divider {
  height: 1px;
  width: 100%;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.1), transparent);
}

/* Auth Section */
.auth-container {
  display: flex;
  flex-direction: column;
  gap: 20px;
  transition: opacity 0.3s ease;
}

/* Clean Form */
.clean-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.form-group label {
  font-size: 12px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.input-wrapper input {
  width: 100%;
  padding: 12px 14px;
  background-color: rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 4px; /* Sharp */
  color: var(--text-main);
  font-size: 15px;
  font-family: var(--font-family-main);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-wrapper input:focus {
  border-color: var(--gold-primary);
  box-shadow: 0 0 0 1px rgba(197, 160, 101, 0.1);
  background-color: rgba(0, 0, 0, 0.5);
}

.input-wrapper input::placeholder {
  color: rgba(255,255,255,0.2);
}

/* Buttons */
.full-width {
  width: 100%;
  justify-content: center;
  padding: 14px;
}

.btn-primary {
  margin-top: 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  background: var(--gold-gradient);
  color: #000;
  border-radius: 2px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(197, 160, 101, 0.2);
}

.btn-primary:active {
  transform: translateY(0);
}

.login-message {
  text-align: center;
  font-size: 13px;
  min-height: 20px;
  color: #ff5555;
}

/* User Welcome Section */
.user-welcome {
  text-align: center;
  animation: fadeIn 0.3s ease;
}

.welcome-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.success-check {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(30, 142, 62, 0.1);
  border: 1px solid #1e8e3e;
  color: #1e8e3e;
  display: flex;
  align-items: center;
  justify-content: center;
}

.user-welcome h2 {
  font-family: var(--font-family-display);
  font-size: 24px;
  color: var(--text-main);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Footer */
.landing-footer {
  text-align: center;
}

.landing-footer p {
  font-size: 12px;
  color: rgba(255, 255, 255, 0.15);
}

/* OTP Input Styles */
.otp-container {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-bottom: 20px;
    width: 100%;
}

.otp-input {
    width: 42px;
    height: 52px;
    background-color: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    color: var(--white);
    font-size: 24px;
    font-weight: 700;
    text-align: center;
    font-family: var(--font-family-display);
    transition: all 0.2s ease;
    caret-color: var(--gold-primary);
    padding: 0;
}

.clean-form .form-group label {
    text-align: center;
    display: block;
    width: 100%;
    margin-bottom: 12px;
}

@media (max-width: 480px) {
    .otp-container {
        gap: 6px;
    }
    .otp-input {
        width: 38px;
        height: 48px;
        font-size: 20px;
    }
    .login-panel {
        padding: 30px 20px;
    }
}

.otp-input:focus {
    border-color: var(--gold-primary);
    box-shadow: 0 0 0 1px rgba(197, 160, 101, 0.3);
    background-color: rgba(0, 0, 0, 0.5);
    outline: none;
    transform: translateY(-2px);
}

.otp-input:not(:placeholder-shown) {
    border-color: rgba(255, 255, 255, 0.3);
}

/* Animations */
@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-4px); }
    20%, 40%, 60%, 80% { transform: translateX(4px); }
}

.otp-error .otp-input {
    border-color: var(--danger);
    animation: shake 0.4s ease-in-out;
}
