/* UNEN Website Stylesheet - Premium Nautical Theme */

/* Variables - Root Colors */
:root {
    --transition-speed: 0.3s;
    --border-radius: 12px;
    --font-primary: 'Inter', sans-serif;
    --font-display: 'Montserrat', sans-serif;
    
    /* Dark Theme (Default) Colors */
    --bg-main: #0b0f19;
    --bg-header: rgba(11, 15, 25, 0.8);
    --bg-card: #141b2c;
    --bg-card-hover: #1c273e;
    --bg-topbar: #070a12;
    --text-primary: #f8fafc;
    --text-secondary: #94a3b8;
    --text-muted: #64748b;
    --border-color: rgba(255, 255, 255, 0.08);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 8px 16px rgba(0, 0, 0, 0.2);
    --shadow-lg: 0 16px 32px rgba(0, 0, 0, 0.3);
    
    /* Semantic Colors */
    --accent: #f97352;
    --accent-glow: rgba(249, 115, 82, 0.2);
    --buoy-red: #ef4444;
    --buoy-green: #10b981;
    --buoy-yellow: #f59e0b;
    --buoy-cardinal: #facc15;
    --buoy-danger: #374151;
    --buoy-special: #eab308;
    
    --bg-light: #090d15;
    --wave-fill: #090d15;
    --primary-gradient: linear-gradient(135deg, #1e3a8a, #0b132b);
}

/* Light Theme Colors */
body.light-theme {
    --bg-main: #f8fafc;
    --bg-header: rgba(248, 250, 252, 0.85);
    --bg-card: #ffffff;
    --bg-card-hover: #f1f5f9;
    --bg-topbar: #0f172a;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --border-color: rgba(0, 0, 0, 0.08);
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 8px 16px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 16px 32px rgba(0, 0, 0, 0.08);
    --bg-light: #f1f5f9;
    --wave-fill: #f1f5f9;
    --primary-gradient: linear-gradient(135deg, #2563eb, #1d4ed8);
}

/* Basic Resets & Layout */
* {
    margin: 0;
    padding: 0;
    box-box: border-box;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: var(--font-primary);
    line-height: 1.6;
    overflow-x: hidden;
    transition: background-color var(--transition-speed), color var(--transition-speed);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    color: #fd9a7f;
    text-decoration: none;
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

.text-center { text-align: center; }
.text-red { color: var(--buoy-red); }
.text-green { color: var(--buoy-green); }
.text-yellow { color: var(--buoy-yellow); }
.text-muted { color: var(--text-muted); }
.hidden { display: none !important; }

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}
::-webkit-scrollbar-track {
    background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
    background: var(--bg-card-hover);
    border-radius: 5px;
    border: 2px solid var(--bg-main);
}
::-webkit-scrollbar-thumb:hover {
    background: var(--accent);
}

/* Utilities / Elements */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: rgba(249, 115, 82, 0.15);
    color: var(--accent);
    padding: 6px 12px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-transform: uppercase;
    margin-bottom: 20px;
    border: 1px solid rgba(249, 115, 82, 0.3);
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: 8px;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
}

.btn-primary {
    background-color: var(--accent);
    color: #ffffff;
    box-shadow: 0 4px 12px var(--accent-glow);
}

.btn-primary:hover {
    background-color: #fc886c;
    color: #ffffff;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(249, 115, 82, 0.4);
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.btn-block {
    display: flex;
    justify-content: center;
    width: 100%;
}

/* Cards & Section headers */
.card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 24px;
    box-shadow: var(--shadow-md);
    transition: transform var(--transition-speed), box-shadow var(--transition-speed), border-color var(--transition-speed), background-color var(--transition-speed);
}

.card:hover {
    border-color: rgba(249, 115, 82, 0.2);
}

.section {
    padding: 24px 0;
    position: relative;
}

.section.bg-light {
    background-color: var(--bg-light);
}

.section-header {
    margin-bottom: 16px;
    max-width: 700px;
}

.section-header.text-center {
    margin-left: auto;
    margin-right: auto;
}

.section-tag {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: block;
    margin-bottom: 8px;
}

.section-header h2 {
    font-family: var(--font-display);
    font-weight: 800;
    font-size: 2.2rem;
    color: var(--text-primary);
    line-height: 1.25;
    margin-bottom: 15px;
}

.section-desc {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Top Toolbar */
.top-bar {
    background-color: var(--bg-topbar);
    border-bottom: 1px solid var(--border-color);
    padding: 8px 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    transition: background-color var(--transition-speed);
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-info {
    display: flex;
    gap: 20px;
}

.top-info i {
    color: var(--accent);
}

.top-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-support {
    font-weight: 600;
    color: var(--text-primary);
}

.theme-toggle-btn {
    background: none;
    border: none;
    color: var(--text-primary);
    cursor: pointer;
    padding: 4px 8px;
    font-size: 1.1rem;
    border-radius: 50%;
    transition: color 0.2s;
}

.theme-toggle-btn:hover {
    color: var(--accent);
}

/* Header */
.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: var(--bg-header);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border-color);
    transition: background-color var(--transition-speed), border-color var(--transition-speed);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    padding-bottom: 15px;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 12px;
}

.compass-logo {
    font-size: 2.2rem;
    color: var(--accent);
    display: flex;
    align-items: center;
}

.fa-spin-slow {
    animation: fa-spin 12s linear infinite;
}

.logo-text h1 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 900;
    line-height: 1;
    letter-spacing: 1px;
    color: var(--text-primary);
}

.logo-text span {
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: block;
    margin-top: 2px;
}

/* Navigation */
.nav ul {
    display: flex;
    gap: 10px;
}

.nav a {
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.95rem;
    padding: 8px 14px;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav a:hover,
.nav a.active {
    color: var(--accent);
    background-color: rgba(249, 115, 82, 0.08);
}

.mobile-nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 6px;
    width: 30px;
}

.mobile-nav-toggle .bar {
    width: 100%;
    height: 2px;
    background-color: var(--text-primary);
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* Hero Section */
.hero {
    position: relative;
    padding: 30px 0 40px 0;
    background-image: url('lancha unen.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    min-height: 320px;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(7, 11, 21, 0.95) 0%, rgba(7, 11, 21, 0.8) 50%, rgba(7, 11, 21, 0.6) 100%);
    z-index: 1;
}

body.light-theme .hero-overlay {
    background: linear-gradient(135deg, rgba(248, 250, 252, 0.95) 0%, rgba(248, 250, 252, 0.85) 50%, rgba(248, 250, 252, 0.6) 100%);
}

.hero-content {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 60px;
    align-items: center;
}

.hero-text-block h2 {
    font-family: var(--font-display);
    font-size: 3rem;
    font-weight: 900;
    line-height: 1.15;
    margin-bottom: 20px;
    letter-spacing: -0.5px;
    color: var(--text-primary);
}

.hero-text-block p {
    font-size: 1.15rem;
    color: var(--text-secondary);
    margin-bottom: 35px;
    max-width: 600px;
}

.hero-buttons {
    display: flex;
    gap: 15px;
}

.hero-stats {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.stat-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 20px 24px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow-md);
    transform: perspective(1000px) rotateY(0deg);
    transition: transform 0.4s ease, border-color 0.4s ease;
}

.stat-card:hover {
    transform: perspective(1000px) rotateY(5deg) translateY(-3px);
    border-color: rgba(249, 115, 82, 0.2);
}

.stat-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
}

.stat-icon.red { background-color: rgba(239, 68, 68, 0.1); color: var(--buoy-red); }
.stat-icon.green { background-color: rgba(16, 185, 129, 0.1); color: var(--buoy-green); }
.stat-icon.yellow { background-color: rgba(245, 158, 11, 0.1); color: var(--buoy-yellow); }

.stat-num {
    font-size: 2rem;
    font-family: var(--font-display);
    font-weight: 800;
    line-height: 1;
    color: var(--text-primary);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-weight: 500;
}

/* Wave SVG */
.wave-container {
    position: absolute;
    bottom: -1px;
    left: 0;
    width: 100%;
    overflow: hidden;
    line-height: 0;
    z-index: 3;
}

.wave-container svg {
    position: relative;
    display: block;
    width: 100%;
    height: 40px;
}

@media (min-width: 768px) {
    .wave-container svg {
        height: 45px;
    }
}

.wave-path {
    fill: var(--wave-fill);
    transition: fill var(--transition-speed);
}

/* Pulsing red dot */
.pulse-red {
    color: var(--buoy-red);
    animation: pulse 1.8s infinite;
}

@keyframes pulse {
    0% { opacity: 0.3; }
    50% { opacity: 1; }
    100% { opacity: 0.3; }
}

/* Map Layout */
.map-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 30px;
    margin-top: 20px;
}

.map-wrapper {
    height: 550px;
    position: relative;
    padding: 0;
    overflow: hidden;
}

#map {
    width: 100%;
    height: 100%;
    z-index: 10;
}

.map-loading {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--bg-card);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    z-index: 20;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.map-loading.fade-out {
    opacity: 0;
    visibility: hidden;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border-color);
    border-top: 4px solid var(--accent);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Side Alerts panel */
.map-sidebar {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.sidebar-card {
    flex: 1;
    display: flex;
    flex-direction: column;
}

.card-title {
    font-family: var(--font-display);
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 18px;
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 10px;
}

.alert-list {
    overflow-y: auto;
    max-height: 250px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-right: 5px;
}

.alert-item {
    background-color: rgba(255, 255, 255, 0.02);
    border-left: 4px solid var(--buoy-yellow);
    padding: 12px;
    border-radius: 0 6px 6px 0;
    font-size: 0.9rem;
    transition: background-color 0.2s;
    cursor: pointer;
}

body.light-theme .alert-item {
    background-color: rgba(0, 0, 0, 0.02);
}

.alert-item:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

body.light-theme .alert-item:hover {
    background-color: rgba(0, 0, 0, 0.04);
}

.alert-item.danger-alert-item {
    border-left-color: var(--buoy-red);
}

.alert-item-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 4px;
    font-weight: 600;
}

.alert-item-body {
    color: var(--text-secondary);
    font-size: 0.82rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.legend-card {
    flex: 0 0 auto;
}

.legend-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.buoy-dot {
    width: 14px;
    height: 14px;
    border-radius: 50%;
    border: 1px solid rgba(255, 255, 255, 0.2);
    flex-shrink: 0;
}

.buoy-dot.safe-water { background: repeating-linear-gradient(90deg, #ff4a4a, #ff4a4a 4px, #ffffff 4px, #ffffff 8px); }
.buoy-dot.lateral-red { background-color: var(--buoy-red); }
.buoy-dot.lateral-green { background-color: var(--buoy-green); }
.buoy-dot.cardinal { background: linear-gradient(180deg, #facc15 50%, #1e293b 50%); }
.buoy-dot.danger { background: linear-gradient(180deg, #1e293b 40%, #ff4a4a 40%, #ff4a4a 60%, #1e293b 60%); }
.buoy-dot.special { background-color: var(--buoy-special); }

/* Custom Leaflet SVG Buoy Marker Styles */
.buoy-marker-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
}

.buoy-icon-svg {
    filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.5));
    transition: transform 0.2s ease;
}

.buoy-icon-svg:hover {
    transform: scale(1.2);
}

/* Pulsing marker light ring */
.light-pulse {
    position: absolute;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    animation: light-glow 1.5s infinite;
    pointer-events: none;
    z-index: -1;
}

.light-pulse.red { background-color: rgba(239, 68, 68, 0.4); }
.light-pulse.green { background-color: rgba(16, 185, 129, 0.4); }
.light-pulse.yellow { background-color: rgba(250, 204, 21, 0.4); }
.light-pulse.white { background-color: rgba(255, 255, 255, 0.6); }

@keyframes light-glow {
    0% { transform: scale(0.3); opacity: 1; }
    100% { transform: scale(1.5); opacity: 0; }
}

/* Popup style */
.leaflet-popup-content-wrapper {
    background-color: var(--bg-card) !important;
    color: var(--text-primary) !important;
    border: 1px solid var(--border-color) !important;
    border-radius: var(--border-radius) !important;
    box-shadow: var(--shadow-lg) !important;
    padding: 5px;
}

.leaflet-popup-tip {
    background-color: var(--bg-card) !important;
    border-left: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.buoy-popup {
    font-family: var(--font-primary);
    min-width: 220px;
    padding: 5px;
}

.buoy-popup h4 {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 6px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 6px;
    color: var(--text-primary);
}

.buoy-popup-status {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.72rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.buoy-popup-status.ok { background-color: rgba(16, 185, 129, 0.15); color: var(--buoy-green); }
.buoy-popup-status.apagada { background-color: rgba(239, 68, 68, 0.15); color: var(--buoy-red); }
.buoy-popup-status.luz-débil { background-color: rgba(245, 158, 11, 0.15); color: var(--buoy-yellow); }
.buoy-popup-status.falta { background-color: rgba(100, 116, 139, 0.15); color: var(--text-muted); }

.buoy-popup-info {
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.buoy-popup-info strong {
    color: var(--text-primary);
}

/* Tables Styling */
.table-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
    padding: 16px 20px;
}

.search-box {
    position: relative;
    flex: 1;
    max-width: 400px;
}

.search-box i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.search-box input {
    width: 100%;
    padding: 10px 14px 10px 40px;
    border-radius: 6px;
    background-color: var(--bg-main);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s;
}

.search-box input:focus {
    border-color: var(--accent);
}

.filter-group {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-btn, .filter-club-btn {
    background: none;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.filter-btn:hover, .filter-club-btn:hover {
    color: var(--text-primary);
    background-color: var(--bg-card-hover);
}

.filter-btn.active, .filter-club-btn.active {
    background-color: var(--accent);
    color: #ffffff;
    border-color: var(--accent);
}

.table-wrapper {
    overflow-x: auto;
    padding: 0;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    font-size: 0.9rem;
}

.data-table th {
    background-color: rgba(255, 255, 255, 0.01);
    color: var(--text-primary);
    font-weight: 600;
    padding: 16px 20px;
    border-bottom: 2px solid var(--border-color);
}

body.light-theme .data-table th {
    background-color: rgba(0, 0, 0, 0.01);
}

.data-table td {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
}

.data-table tbody tr {
    transition: background-color 0.15s;
}

.data-table tbody tr:hover {
    background-color: rgba(255, 255, 255, 0.01);
}

body.light-theme .data-table tbody tr:hover {
    background-color: rgba(0, 0, 0, 0.01);
}

.table-status-pill {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
}

.table-status-pill.ok { background-color: rgba(16, 185, 129, 0.15); color: var(--buoy-green); }
.table-status-pill.apagada { background-color: rgba(239, 68, 68, 0.15); color: var(--buoy-red); }
.table-status-pill.luz-débil { background-color: rgba(245, 158, 11, 0.15); color: var(--buoy-yellow); }
.table-status-pill.falta { background-color: rgba(100, 116, 139, 0.15); color: var(--text-muted); }

.map-zoom-link {
    color: var(--accent);
    cursor: pointer;
    font-size: 1.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background-color: rgba(249, 115, 82, 0.08);
    transition: all 0.2s;
}

.map-zoom-link:hover {
    background-color: var(--accent);
    color: white;
    transform: scale(1.1);
}

/* Cables Specific Styling */
.danger-alert {
    background-color: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: var(--border-radius);
    padding: 20px;
    display: flex;
    gap: 15px;
    align-items: center;
    margin-bottom: 25px;
}

.danger-alert .alert-icon {
    font-size: 2rem;
    color: var(--buoy-red);
}

.danger-alert .alert-text {
    color: var(--text-primary);
    font-size: 0.95rem;
}

/* Gallery Section */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin-top: 25px;
}

.gallery-item {
    position: relative;
    border-radius: var(--border-radius);
    overflow: hidden;
    height: 200px;
    box-shadow: var(--shadow-md);
    cursor: pointer;
    border: 1px solid var(--border-color);
}

.gallery-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    padding: 20px;
    background: linear-gradient(0deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0) 100%);
    color: white;
    opacity: 0;
    transform: translateY(10px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.gallery-item:hover .gallery-img {
    transform: scale(1.08);
}

.gallery-item:hover .gallery-overlay {
    opacity: 1;
    transform: translateY(0);
}

.gallery-overlay h4 {
    font-family: var(--font-display);
    font-size: 1rem;
    font-weight: 700;
}

/* Timeline/Novedades */
.timeline {
    position: relative;
    max-width: 800px;
    margin: 30px auto 0 auto;
    padding-left: 30px;
}

.timeline::before {
    content: '';
    position: absolute;
    top: 5px;
    left: 7px;
    width: 2px;
    height: 98%;
    background-color: var(--border-color);
}

.timeline-item {
    position: relative;
    margin-bottom: 40px;
}

.timeline-dot {
    position: absolute;
    left: -29px;
    top: 6px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background-color: var(--accent);
    border: 3px solid var(--bg-main);
    box-shadow: 0 0 0 3px rgba(249, 115, 82, 0.2);
}

.timeline-date {
    font-family: var(--font-display);
    font-size: 0.9rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 8px;
    display: block;
}

.timeline-card {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    padding: 20px 24px;
    box-shadow: var(--shadow-sm);
}

.timeline-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* History Layout */
.history-layout {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 50px;
    align-items: start;
}

.history-text {
    color: var(--text-secondary);
    font-size: 1.05rem;
    line-height: 1.7;
}

.history-text h3 {
    font-family: var(--font-display);
    font-size: 1.4rem;
    color: var(--text-primary);
    margin: 30px 0 15px 0;
}

.history-text p {
    margin-bottom: 20px;
}

.history-sidebar {
    display: flex;
    flex-direction: column;
    gap: 30px;
    position: sticky;
    top: 100px;
}

.history-card h3 {
    font-family: var(--font-display);
    font-size: 1.15rem;
    margin-bottom: 12px;
}

.bg-primary-gradient {
    background: var(--primary-gradient);
}

.text-white {
    color: white !important;
}

.text-white p {
    color: rgba(255, 255, 255, 0.85);
}

.timeline-summary {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.timeline-summary li {
    font-size: 0.9rem;
    color: var(--text-secondary);
    border-left: 2px solid var(--accent);
    padding-left: 12px;
}

/* Tabs System */
.tabs-container {
    background-color: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-md);
}

.tabs-nav {
    display: flex;
    background-color: rgba(0, 0, 0, 0.2);
    border-bottom: 1px solid var(--border-color);
}

body.light-theme .tabs-nav {
    background-color: #f1f5f9;
}

.tab-btn {
    flex: 1;
    background: none;
    border: none;
    padding: 18px 24px;
    color: var(--text-secondary);
    font-family: var(--font-display);
    font-weight: 700;
    font-size: 1.05rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.2s;
    border-bottom: 3px solid transparent;
}

.tab-btn:hover {
    color: var(--text-primary);
    background-color: rgba(255, 255, 255, 0.02);
}

.tab-btn.active {
    color: var(--accent);
    border-bottom-color: var(--accent);
    background-color: var(--bg-card);
}

.tab-panel {
    display: none;
    padding: 30px;
}

.tab-panel.active {
    display: block;
}

.panel-header {
    margin-bottom: 30px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 20px;
}

.panel-header h3 {
    font-family: var(--font-display);
    font-size: 1.5rem;
    margin-bottom: 6px;
    color: var(--text-primary);
}

.panel-header p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.panel-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-top: 20px;
}

/* Clubs Grid */
.club-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
}

.club-card {
    background-color: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    transition: border-color 0.2s, transform 0.2s;
}

.club-card:hover {
    border-color: rgba(249, 115, 82, 0.3);
    transform: translateY(-2px);
}

.club-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 10px;
}

.club-name {
    font-family: var(--font-display);
    font-size: 1.05rem;
    font-weight: 700;
    line-height: 1.3;
    color: var(--text-primary);
}

.club-badge {
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 4px;
    text-transform: uppercase;
}

.club-badge.activos { background-color: rgba(16, 185, 129, 0.12); color: var(--buoy-green); }
.club-badge.adherentes { background-color: rgba(37, 99, 235, 0.12); color: #60a5fa; }

.club-details {
    font-size: 0.85rem;
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 15px;
}

.club-details i {
    width: 16px;
    color: var(--accent);
}

.club-actions {
    border-top: 1px solid var(--border-color);
    padding-top: 12px;
}

.btn-club-link {
    font-size: 0.82rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* Committee Grid */
.committee-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.committee-card {
    background-color: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    text-align: center;
}

.committee-role {
    font-size: 0.72rem;
    font-weight: 700;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
    display: block;
}

.committee-name {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 4px;
    color: var(--text-primary);
}

.committee-club {
    font-size: 0.82rem;
    color: var(--text-secondary);
    font-style: italic;
}

/* Contact and Report Form */
.contact-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
}

.info-details {
    display: flex;
    flex-direction: column;
    gap: 25px;
    margin: 30px 0;
}

.info-item {
    display: flex;
    gap: 15px;
}

.info-icon {
    width: 48px;
    height: 48px;
    background-color: rgba(249, 115, 82, 0.08);
    color: var(--accent);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

.info-txt h4 {
    font-family: var(--font-display);
    font-size: 1.05rem;
    margin-bottom: 4px;
    color: var(--text-primary);
}

.info-txt p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.useful-links {
    padding: 20px;
}

.useful-links h4 {
    font-family: var(--font-display);
    font-size: 1.05rem;
    margin-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 8px;
}

.link-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.link-list li a {
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--text-secondary);
}

.link-list li a:hover {
    color: var(--accent);
}

/* Form panel styles */
.form-card {
    padding: 30px;
}

.form-title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 25px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

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

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 11px 14px;
    border-radius: 6px;
    background-color: var(--bg-main);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 0.9rem;
    outline: none;
    transition: border-color 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--accent);
}

.form-feedback {
    margin-top: 15px;
    padding: 12px;
    border-radius: 6px;
    font-size: 0.9rem;
    text-align: center;
}

.form-feedback.success {
    background-color: rgba(16, 185, 129, 0.12);
    color: var(--buoy-green);
    border: 1px solid rgba(16, 185, 129, 0.2);
}

.form-feedback.error {
    background-color: rgba(239, 68, 68, 0.12);
    color: var(--buoy-red);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

/* Footer Bottom */
.footer-bottom {
    background-color: var(--bg-topbar);
    border-top: 1px solid var(--border-color);
    padding: 40px 0;
    font-size: 0.85rem;
    color: var(--text-muted);
    transition: background-color var(--transition-speed);
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 30px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-logo i {
    font-size: 1.8rem;
    color: var(--accent);
}

.footer-logo h4 {
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.footer-logo p {
    font-size: 0.72rem;
    color: var(--text-secondary);
}

.copyright {
    text-align: center;
}

.footer-links {
    display: flex;
    gap: 20px;
}

.footer-links a {
    color: var(--text-muted);
}

.footer-links a:hover {
    color: var(--accent);
}

/* Mobile Responsive styling */
@media (max-width: 992px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .hero-stats {
        flex-direction: row;
        flex-wrap: wrap;
    }
    
    .stat-card {
        flex: 1 1 200px;
    }
    
    .map-layout {
        grid-template-columns: 1fr;
    }
    
    .map-wrapper {
        height: 400px;
    }
    
    .history-layout {
        grid-template-columns: 1fr;
    }
    
    .history-sidebar {
        position: relative;
        top: 0;
    }
    
    .contact-layout {
        grid-template-columns: 1fr;
        gap: 40px;
    }
}

@media (max-width: 768px) {
    .section {
        padding: 50px 0;
    }
    
    .section-header h2 {
        font-size: 1.8rem;
    }
    
    .hero-text-block h2 {
        font-size: 2.2rem;
    }
    
    .top-info {
        display: none;
    }
    
    .top-bar-content {
        justify-content: flex-end;
    }
    
    .mobile-nav-toggle {
        display: flex;
        z-index: 1100;
    }
    
    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background-color: var(--bg-card);
        box-shadow: var(--shadow-lg);
        z-index: 1050;
        padding: 80px 30px;
        transition: right 0.3s ease;
        border-left: 1px solid var(--border-color);
    }
    
    .nav.open {
        right: 0;
    }
    
    .nav ul {
        flex-direction: column;
        gap: 15px;
    }
    
    .nav a {
        font-size: 1.1rem;
        padding: 10px 14px;
        width: 100%;
    }
    
    /* Menu Button active animations */
    .mobile-nav-toggle.open .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    .mobile-nav-toggle.open .bar:nth-child(2) {
        opacity: 0;
    }
    .mobile-nav-toggle.open .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    .table-controls {
        flex-direction: column;
        align-items: stretch;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    .footer-content {
        flex-direction: column;
        text-align: center;
    }
}
