/* =====================================================
   SISTEMA DE DISEÑO GLOBAL - EMAUS PARROQUIA
   ===================================================== */

:root {
    /* Variables del Sistema Administrativo */
    --primary-color:  #1e1b4b; /* Deep Indigo */
    --secondary-color:#312e81;
    --accent-color:   #d4af37;
    --accent-hover:   #b8860b;
    --text-main:      #1e293b;
    --text-muted:     #64748b;
    --bg-color:       #f8fafc;
    --bg-card:        #ffffff;
    --card-bg:        #ffffff;
    --border-color:   #e2e8f0;
    --border-radius:  20px;
    --shadow-sm:      0 1px 3px rgba(0,0,0,0.08);
    --shadow-md:      0 10px 25px -5px rgba(0,0,0,0.1);
    --shadow-lg:      0 20px 50px rgba(0,0,0,0.12);
    --danger-color:   #ef4444;
    --success-color:  #10b981;

    /* Indigo Premium Palette */
    --indigo-50:  #eef2ff;
    --indigo-100: #e0e7ff;
    --indigo-500: #6366f1;
    --indigo-600: #4f46e5;
    --indigo-700: #4338ca;
    --indigo-900: #1e1b4b;
    
    /* Divine Gold Palette */
    --gold-primary: #d4af37;
    --gold-light:   #fde68a;
    --gold-dark:    #b8961f;

    /* Glass Effect */
    --glass-bg: rgba(255, 255, 255, 0.85);
    --glass-border: rgba(255, 255, 255, 0.3);
    --glass-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);

    /* Variables del Landing Page */
    --primary:        #0f172a;  /* Midnight Indigo */
    --accent:         #d4af37;  /* Divine Gold */
    --accent-glow:    rgba(212, 175, 55, 0.4);
    --dark:           #0f172a;
    --light:          #f8fafc;
    --white:          #ffffff;
    --shadow:         0 4px 20px rgba(0,0,0,0.15);
    --card-shadow:    0 20px 50px rgba(0,0,0,0.1);
    --transition:     all 0.3s ease;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { font-family: 'Playfair Display', 'Inter', sans-serif; }

/* =====================================================
   COMPONENTES ADMINISTRATIVOS (Dashboard, WS, etc.)
   ===================================================== */

/* Navbar Admin */
.top-navbar {
    background: var(--primary-color);
    color: white;
    padding: 0.75rem 2rem;
    display: flex;
    justify-content: space-between;
    z-index: 1000;
    box-shadow: var(--shadow-md);
    flex-wrap: wrap;
    gap: 1rem;
}
.navbar-brand {
    font-weight: 700; font-size: 1.25rem;
    display: flex; align-items: center; gap: 10px;
    text-decoration: none; color: white; flex: 1; min-width: 200px;
}
.navbar-user {
    display: flex; align-items: center; gap: 15px; font-size: 0.9rem;
}

/* Dashboard */
.dashboard-body   { background-color: var(--bg-color); min-height: 100vh; padding: 40px 20px; }
.dashboard-container { max-width: 1200px; margin: 0 auto; }
.dashboard-header { text-align: center; margin-bottom: 50px; }
.dashboard-header h1 {
    font-size: 2.8rem; color: var(--primary-color);
    font-weight: 800; letter-spacing: -1px; margin-bottom: 10px;
}
.admin-section-header {
    grid-column: 1 / -1; margin: 40px 0 20px;
    font-size: 1.1rem; text-transform: uppercase; letter-spacing: 1px;
    color: var(--text-muted); font-weight: 700;
    display: flex; align-items: center; gap: 15px;
}
.admin-section-header::after {
    content: ""; flex: 1; height: 1px; background: var(--border-color);
}

/* Cards Admin */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
}
.dashboard-card {
    background: var(--card-bg);
    padding: 40px; border-radius: var(--border-radius);
    text-decoration: none; color: var(--text-main);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: var(--shadow-sm);
    display: flex; flex-direction: column; align-items: center;
    border: 1px solid var(--border-color);
    position: relative; overflow: hidden;
}
.dashboard-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
    border-color: var(--accent-color);
}
.dashboard-card::before {
    content: ""; position: absolute; top: 0; left: 0;
    width: 100%; height: 4px;
    background: var(--accent-color); transform: scaleX(0);
    transition: transform 0.4s ease;
}
.dashboard-card:hover::before { transform: scaleX(1); }
.card-icon { font-size: 3.5rem; margin-bottom: 20px; transition: transform 0.3s ease; }
.dashboard-card:hover .card-icon { transform: scale(1.1); }
.dashboard-card h3 { font-size: 1.4rem; font-weight: 700; margin-bottom: 10px; }
.dashboard-card p  { font-size: 0.95rem; color: var(--text-muted); text-align: center; }

/* Buttons */
.btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 0.75rem 1.5rem;
    background-color: var(--accent-color);
    color: white; text-decoration: none;
    border-radius: var(--border-radius); border: none;
    cursor: pointer; font-size: 0.95rem; font-weight: 600;
    transition: all 0.3s ease; gap: 8px;
}
.btn:hover { background-color: var(--accent-hover); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-secondary { background-color: var(--secondary-color); }
.btn-danger    { background-color: var(--danger-color); }
.btn-success   { background-color: var(--success-color); }

/* Tables */
.data-table-container {
    background: var(--card-bg); border-radius: var(--border-radius);
    overflow: hidden; box-shadow: var(--shadow-md);
    border: 1px solid var(--border-color);
}
.data-table { width: 100%; border-collapse: collapse; }
.data-table th {
    background-color: #f8fafc; color: var(--text-muted);
    font-weight: 700; text-transform: uppercase; font-size: 0.75rem;
    letter-spacing: 0.05em; padding: 1rem 1.5rem;
    text-align: left; border-bottom: 2px solid var(--border-color);
}
.data-table td  { padding: 1.25rem 1.5rem; border-bottom: 1px solid var(--border-color); color: var(--text-main); font-size: 0.95rem; }
.data-table tr:hover { background-color: #f1f5f9; }
.badge { padding: 0.25rem 0.75rem; border-radius: 9999px; font-size: 0.75rem; font-weight: 700; }

/* Forms */
.card {
    background: var(--card-bg); padding: 2.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-md); border: 1px solid var(--border-color);
}
input, select, textarea {
    width: 100%; padding: 0.75rem 1rem;
    border: 1.5px solid var(--border-color); border-radius: 8px;
    font-size: 1rem; transition: all 0.3s ease; background: #fff;
    font-family: inherit;
}
input:focus, select:focus, textarea:focus {
    outline: none; border-color: var(--accent-color);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.15);
}

/* Utils */
.container { max-width: 1200px; margin: 3rem auto; padding: 0 20px; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1rem; }
.form-group { margin-bottom: 1.25rem; }
label { display: block; margin-bottom: 0.5rem; font-weight: 600; color: var(--secondary-color); font-size: 0.9rem; }
.hidden { display: none; }

/* =====================================================
   LANDING PAGE PÚBLICA (index.php)
   ===================================================== */

/* Navbar Landing */
.navbar {
    position: fixed; top: 0; width: 100%;
    padding: 28px 5%; display: flex;
    justify-content: space-between; align-items: center;
    z-index: 1000; transition: all 0.4s cubic-bezier(0.4,0,0.2,1);
}
.navbar.scrolled {
    padding: 14px 5%;
    background: rgba(15,23,42,0.92);
    backdrop-filter: blur(15px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}
.logo {
    display: flex; align-items: center; gap: 12px;
    text-decoration: none; color: white;
    font-size: 1.4rem; font-weight: 800; font-family: 'Outfit', sans-serif;
}
.logo-img {
    height: 75px;
    width: auto;
    border-radius: 50%;
    box-shadow: 0 0 15px rgba(212, 175, 55, 0.4), inset 0 0 10px rgba(255,255,255,0.2);
    transition: transform 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    border: 2px solid rgba(212, 175, 55, 0.6);
    padding: 3px;
    background: rgba(15, 23, 42, 0.5);
    backdrop-filter: blur(4px);
}
.logo:hover .logo-img {
    transform: scale(1.08) rotate(3deg);
    border-color: var(--accent);
    box-shadow: 0 0 25px rgba(212, 175, 55, 0.6);
}
.nav-links { display: flex; gap: 28px; list-style: none; align-items: center; }
.nav-links a {
    color: white; text-decoration: none; font-weight: 500;
    font-size: 0.92rem; opacity: 0.85; transition: opacity 0.3s, color 0.3s;
}
.nav-links a:hover { opacity: 1; color: var(--accent); }
.btn-access {
    background: var(--accent); color: var(--primary) !important;
    padding: 10px 24px; border-radius: 50px; font-weight: 700;
    box-shadow: 0 8px 20px var(--accent-glow); transition: transform 0.3s;
    text-decoration: none; display: inline-flex; align-items: center; gap: 8px;
}
.btn-access:hover { transform: translateY(-3px); opacity: 1; }
.gold-text {
    background: linear-gradient(to bottom, #fde68a, #d4af37);
    -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}

/* Hero */
.hero {
    height: 100vh; background-size: cover; background-position: center;
    position: relative; display: flex; align-items: center;
    justify-content: center; text-align: center; color: white;
}
.hero-overlay {
    position: absolute; inset: 0;
    background: linear-gradient(to bottom, rgba(15,23,42,0.82), rgba(15,23,42,0.45));
}
.hero-content { position: relative; z-index: 10; max-width: 1000px; padding: 0 30px; }
.hero h1 {
    font-size: clamp(2.5rem, 7vw, 5rem); line-height: 1.05;
    margin-bottom: 1.5rem; color: white; font-family: 'Playfair Display', serif;
}
.hero-date {
    background: var(--accent); color: var(--primary);
    padding: 8px 24px; border-radius: 50px; font-weight: 700;
    display: inline-block; margin-bottom: 1.5rem;
}
.btn-outline-hero {
    background: transparent; border: 2px solid white;
    color: white !important; box-shadow: none;
}

/* Sections */
section { padding: 100px 10%; }

.section-title { text-align: center; margin-bottom: 70px; }
.section-title h2 {
    font-size: 2.8rem; font-family: 'Playfair Display', serif;
    display: inline-block; padding-bottom: 15px;
    border-bottom: 4px solid var(--accent);
}

/* Social Wall */
.social-wall {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 28px;
}
.social-card { aspect-ratio: 1; border-radius: 18px; overflow: hidden; position: relative; box-shadow: var(--card-shadow); }
.social-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.social-card:hover img { transform: scale(1.1); }
.social-card .card-overlay {
    position: absolute; inset: 0; background: rgba(15,23,42,0.82);
    backdrop-filter: blur(5px); display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    color: white; opacity: 0; transition: opacity 0.4s;
}
.social-card:hover .card-overlay { opacity: 1; }

/* Footer Landing */
footer { background: var(--primary); color: white; padding: 80px 10% 40px; }
.footer-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 50px; margin-bottom: 50px;
}

/* Animations */
.reveal { opacity: 0; transform: translateY(30px); transition: all 0.8s ease; }
.reveal.active { opacity: 1; transform: translateY(0); }
.fade-in { opacity: 0; transform: translateY(20px); transition: opacity 0.8s ease, transform 0.8s ease; }
.fade-in.visible { opacity: 1; transform: translateY(0); }

/* =====================================================
   RESPONSIVE
   ===================================================== */
@media (max-width: 768px) {
    .top-navbar       { padding: 1rem !important; flex-direction: column !important; align-items: center !important; }
    .navbar-brand     { font-size: 1rem !important; justify-content: center !important; }
    .navbar-user      { width: 100% !important; justify-content: center !important; flex-direction: column !important; }
    .dashboard-header h1 { font-size: 1.8rem; }
    .dashboard-body   { padding: 20px 10px; }
    .card             { padding: 1.5rem 1rem; }
    .nav-links        { display: none; }
    .logo-img         { height: 55px; }
    .hero h1          { font-size: 2.5rem; }
    section           { padding: 70px 6%; }
}
@media (max-width: 480px) {
    .dashboard-grid, .grid { grid-template-columns: 1fr; }
    .dashboard-card { padding: 20px; }
}