/* Base Variables */
:root {
    --bg-base: #0a0b0f;
    --bg-darker: #050608;
    --text-main: #f0f2f5;
    --text-muted: #8b92a5;
    --accent: #d4af37; /* Apostolic Gold */
    --accent-glow: rgba(212, 175, 55, 0.2);
    --blue-glow: rgba(59, 130, 246, 0.15);
    --purple-glow: rgba(139, 92, 246, 0.15);
    
    --glass-bg: rgba(20, 24, 31, 0.4);
    --glass-border: rgba(255, 255, 255, 0.08);
}

/* Reset & Scaffolding */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, sans-serif;
    background-color: var(--bg-base);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    position: relative;
}

h1, h2, h3, .logo-text {
    font-family: 'Playfair Display', serif;
    font-weight: 500;
}

/* Typography Scale */
h1 { font-size: clamp(3.5rem, 8vw, 6rem); line-height: 1.1; letter-spacing: -2px; }
h2 { font-size: clamp(2.5rem, 5vw, 4rem); line-height: 1.2; margin-bottom: 20px; letter-spacing: -1px; }
h3 { font-size: 1.75rem; margin-bottom: 10px; color: #fff; }
p { margin-bottom: 20px; font-size: 1.1rem; font-weight: 300; }
p:last-child { margin-bottom: 0; }

.subheading {
    display: block;
    font-family: 'Inter', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--accent);
    margin-bottom: 15px;
}

.text-muted { color: var(--text-muted); }
.text-center { text-align: center; }
.max-w-3xl { max-width: 48rem; }
.mx-auto { margin-left: auto; margin-right: auto; }
.mt-4 { margin-top: 2rem; }
.mb-4 { margin-bottom: 2rem; }

/* Links & Buttons */
a { text-decoration: none; color: inherit; transition: color 0.3s ease; }
.text-link { color: var(--accent); font-weight: 500; display: inline-block; margin-top: 15px; }
.text-link:hover { text-shadow: 0 0 10px var(--accent-glow); }

.btn-primary, .btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 28px;
    border-radius: 100px;
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.btn-primary {
    background: #fff;
    color: #000;
    box-shadow: 0 10px 30px rgba(255,255,255,0.1);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 15px 40px rgba(255,255,255,0.2);
    background: #f0f0f0;
}

.btn-secondary {
    background: transparent;
    color: #fff;
    border: 1px solid var(--glass-border);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255,255,255,0.05);
    border-color: rgba(255,255,255,0.2);
}

/* Layout Utilities */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 5%;
}

.section { padding: 120px 0; position: relative; z-index: 10; }
.min-h-screen { min-height: 100vh; }
.bg-darker { background-color: var(--bg-darker); }
.border-top { border-top: 1px solid var(--glass-border); }

.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
}

.divider {
    height: 1px;
    width: 60px;
    background: var(--accent);
    margin: 30px 0;
}

/* Glassmorphism Components */
.glass-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 40px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    box-shadow: 0 30px 60px rgba(0,0,0,0.4);
    position: relative;
    overflow: hidden;
}

/* Ambient Background */
.ambient-background {
    position: fixed;
    top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}

.orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.6;
    animation: float 20s infinite ease-in-out alternate;
}

.orb-1 {
    top: -10%; left: -10%;
    width: 50vw; height: 50vw;
    background: radial-gradient(circle, var(--blue-glow), transparent 70%);
}

.orb-2 {
    bottom: -20%; right: -10%;
    width: 60vw; height: 60vw;
    background: radial-gradient(circle, var(--purple-glow), transparent 70%);
    animation-delay: -5s;
}

.orb-3 {
    top: 40%; left: 60%;
    width: 40vw; height: 40vw;
    background: radial-gradient(circle, var(--accent-glow), transparent 70%);
    animation-delay: -10s;
}

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(5%, 10%) scale(1.1); }
}

/* Navbar */
.navbar {
    position: fixed;
    top: 0; left: 0; width: 100%;
    padding: 24px 0;
    z-index: 100;
    transition: all 0.4s ease;
}

.navbar.scrolled {
    background: rgba(10, 11, 15, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 16px 0;
    border-bottom: 1px solid var(--glass-border);
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

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

.logo-mark {
    font-family: 'Playfair Display', serif;
    font-size: 1.5rem;
    color: var(--accent);
    border: 1px solid var(--accent);
    width: 40px; height: 40px;
    display: flex; justify-content: center; align-items: center;
    border-radius: 50%;
}

.logo-text { font-size: 1.25rem; }

.nav-links {
    display: flex;
    align-items: center;
    gap: 32px;
}

.nav-links a { font-size: 0.9rem; font-weight: 500; }
.nav-links a:hover { color: var(--accent); }
.nav-links .btn-primary { padding: 10px 24px; color: #000; }
.nav-links .btn-primary:hover { color: #000; }

/* Hero Section */
.hero {
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 10;
    padding-top: 80px;
}

.hero-content {
    text-align: center;
    max-width: 900px;
    padding: 0 5%;
}

.hero-badge {
    display: inline-block;
    padding: 6px 16px;
    border: 1px solid var(--glass-border);
    border-radius: 100px;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 2px;
    background: rgba(255,255,255,0.03);
    margin-bottom: 30px;
}

.hero-title i { font-style: italic; color: var(--accent); }

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 30px auto 40px;
}

.hero-actions {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.5;
}

.scroll-indicator span { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 2px; }

.scroll-line {
    width: 1px;
    height: 40px;
    background: linear-gradient(to bottom, currentColor 50%, transparent 50%);
    background-size: 100% 200%;
    animation: scanLine 2s infinite linear;
}

@keyframes scanLine {
    0% { background-position: 100% -100%; }
    100% { background-position: 100% 100%; }
}

/* Cards & Rooms */
.card-icon {
    width: 60px; height: 60px;
    background: rgba(255,255,255,0.05);
    border-radius: 16px;
    display: flex; justify-content: center; align-items: center;
    margin-bottom: 24px;
    color: var(--accent);
}

.room-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-top: 60px;
}

.room-card {
    padding: 50px 40px;
    transition: transform 0.4s ease, background 0.4s ease;
}

.room-card:hover {
    transform: translateY(-10px);
    background: rgba(30, 36, 46, 0.6);
    border-color: rgba(255,255,255,0.15);
}

.room-number {
    font-family: 'Playfair Display', serif;
    font-size: 4rem;
    color: rgba(255,255,255,0.05);
    position: absolute;
    top: 20px; right: 30px;
    line-height: 1;
    font-style: italic;
    transition: color 0.4s ease;
}

.room-card:hover .room-number { color: rgba(212, 175, 55, 0.15); }

.room-subtitle { color: var(--accent); font-weight: 600; font-size: 0.9rem; letter-spacing: 1px; text-transform: uppercase; margin-bottom: 20px; }

/* Features List */
.feature-list { list-style: none; margin-top: 30px; }
.feature-list li {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    align-items: flex-start;
}
.feature-list li:last-child { margin-bottom: 0; }
.feature-icon { color: var(--accent); margin-top: 3px; }

/* CSS Abstract Arts */
.image-placeholder { min-height: 400px; display: flex; justify-content: center; align-items: center; }

/* Ring System Animation */
.ring-system { position: relative; width: 200px; height: 200px; }
.ring {
    position: absolute; top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    border-radius: 50%; border: 1px solid rgba(255,255,255,0.1);
}
.r1 { width: 100%; height: 100%; animation: spin 20s linear infinite; border-top-color: var(--accent); }
.r2 { width: 70%; height: 70%; animation: spin 15s linear infinite reverse; border-right-color: #3b82f6; }
.r3 { width: 40%; height: 40%; animation: spin 10s linear infinite; border-bottom-color: #8b5cf6; }
.core-node {
    position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
    width: 10px; height: 10px; background: #fff; border-radius: 50%;
    box-shadow: 0 0 20px 5px rgba(255,255,255,0.4);
}

@keyframes spin { 100% { transform: translate(-50%, -50%) rotate(360deg); } }

/* Footer */
.footer { border-top: 1px solid var(--glass-border); padding: 60px 0; background: #000; position: relative; z-index: 10; }
.footer-links { display: flex; justify-content: center; gap: 30px; }
.footer-links a { font-size: 0.9rem; color: var(--text-muted); }
.footer-links a:hover { color: #fff; }

/* Portal Layout (Curriculum) */
.portal-wrapper {
    display: flex;
    max-width: 1400px;
    margin: 120px auto 100px;
    padding: 0 5%;
    gap: 40px;
    position: relative;
    z-index: 10;
}

.portal-sidebar {
    width: 320px;
    flex-shrink: 0;
    position: sticky;
    top: 100px;
    height: calc(100vh - 120px);
    overflow-y: auto;
    padding: 30px;
    /* Custom scrollbar for sidebar */
}

.portal-sidebar::-webkit-scrollbar {
    width: 4px;
}
.portal-sidebar::-webkit-scrollbar-track {
    background: transparent;
}
.portal-sidebar::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,0.1);
    border-radius: 10px;
}

.portal-nav-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 25px;
}

.portal-nav-link {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 14px 18px;
    border-radius: 12px;
    color: var(--text-muted);
    font-weight: 500;
    transition: all 0.3s ease;
    border: 1px solid transparent;
    cursor: pointer;
}

.portal-nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
}

.portal-nav-link.active {
    background: rgba(212, 175, 55, 0.1);
    color: var(--text-main);
    border-color: rgba(212, 175, 55, 0.3);
}

.portal-nav-num {
    font-family: 'Playfair Display', serif;
    color: var(--accent);
    font-size: 1.2rem;
    font-style: italic;
    min-width: 25px;
}

.portal-content {
    flex-grow: 1;
    min-width: 0;
}

.module-content {
    display: none;
    animation: fadeIn 0.5s ease forwards;
}

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

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

/* Advertorial Typography */
.advertorial-body {
    margin-top: 40px;
    font-size: 1.15rem;
    line-height: 1.8;
    color: #d1d5db;
}

.advertorial-body h2 {
    font-size: 2.2rem;
    margin: 50px 0 20px;
    color: #fff;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    padding-bottom: 10px;
}

.advertorial-body h3 {
    font-size: 1.6rem;
    margin: 40px 0 15px;
    color: var(--accent);
}

.advertorial-body p {
    margin-bottom: 25px;
}

.advertorial-body ul {
    margin: 20px 0 35px 20px;
    list-style-type: none;
    background: rgba(0,0,0,0.2);
    padding: 30px;
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.05);
}

.advertorial-body ul li {
    position: relative;
    padding-left: 30px;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.advertorial-body ul li:last-child {
    margin-bottom: 0;
}

.advertorial-body ul li::before {
    content: "→";
    position: absolute;
    left: 0;
    color: var(--accent);
    font-weight: bold;
}

.advertorial-body .lead {
    font-size: 1.35rem;
    color: #fff;
    font-weight: 400;
    border-left: 4px solid var(--accent);
    padding-left: 24px;
    margin-bottom: 40px;
    line-height: 1.6;
}

.advertorial-body .highlight-box {
    background: linear-gradient(145deg, rgba(212,175,55,0.1) 0%, rgba(212,175,55,0.02) 100%);
    border: 1px solid rgba(212,175,55,0.3);
    padding: 30px;
    border-radius: 16px;
    margin: 40px 0;
}

.advertorial-body .highlight-box h3 {
    margin-top: 0;
}

/* Responsive */
@media (max-width: 968px) {
    .section { padding: 60px 0; }
    .glass-card { padding: 30px 20px; }
    .room-card { padding: 30px 20px; }
    .grid-2 { grid-template-columns: 1fr; gap: 40px; }
    .room-grid { grid-template-columns: 1fr; }
    .nav-links { display: none; }
    h1 { font-size: 3rem; }
    h2 { font-size: 2.2rem; }
    .hero-actions { flex-direction: column; }
    .reverse-mobile { flex-direction: column-reverse; display: flex; }
    
    /* Portal Mobile */
    .portal-wrapper {
        flex-direction: column;
        margin-top: 80px;
        gap: 20px;
    }
    
    .portal-sidebar {
        width: 100%;
        position: relative;
        top: 0;
        height: auto;
        padding: 20px;
        z-index: 50;
    }
    
    .portal-nav-list {
        flex-direction: row;
        overflow-x: auto;
        padding-bottom: 15px;
        -webkit-overflow-scrolling: touch;
        gap: 15px;
        margin-top: 15px;
    }
    
    .portal-nav-link {
        white-space: nowrap;
        padding: 12px 20px;
        border: 1px solid rgba(255,255,255,0.1);
        border-radius: 100px;
    }
    
    .portal-nav-link.active {
        border-color: var(--accent);
    }
    
    .portal-sidebar::-webkit-scrollbar {
        height: 6px;
        width: 0;
    }
    .portal-sidebar::-webkit-scrollbar-track, .portal-nav-list::-webkit-scrollbar-track {
        background: rgba(255,255,255,0.02);
        border-radius: 10px;
        margin: 0 10px;
    }
    .portal-sidebar::-webkit-scrollbar-thumb, .portal-nav-list::-webkit-scrollbar-thumb {
        background: rgba(212,175,55,0.3);
        border-radius: 10px;
    }
}

/* Visibility classes for GSAP */
.gsap-reveal, .gsap-reveal-left, .gsap-reveal-right, .gsap-reveal-stagger {
    visibility: hidden;
}

/* ========================================================================= */
/* COMMENT SYSTEM STYLES                                                     */
/* ========================================================================= */

#comments-section {
    border-top: 1px solid var(--glass-border);
}

.comment-box {
    background: rgba(45, 23, 111, 0.4); 
    border: 1px solid var(--glass-border); 
    padding: 20px; 
    border-radius: 12px; 
    margin-bottom: 15px; 
    text-align: left;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.comment-box:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.comment-header {
    display: flex; 
    align-items: center; 
    margin-bottom: 10px;
}

.comment-avatar {
    width: 35px; 
    height: 35px; 
    border-radius: 50%; 
    background: var(--accent); 
    color: white; 
    display: flex; 
    align-items: center; 
    justify-content: center; 
    font-weight: bold; 
    margin-right: 15px; 
    flex-shrink: 0;
    box-shadow: 0 0 10px rgba(139, 92, 246, 0.5);
}

.comment-body {
    color: rgba(255,255,255,0.9); 
    font-size: 0.95rem; 
    line-height: 1.5; 
    padding-left: 50px; 
    white-space: pre-wrap;
}
