@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;700&family=Inter:wght@300;400;500;600&display=swap');

:root {
  /* Cortex Subtle Blue Theme */
  --bg-color: #f3f4f6;
  --panel-bg: rgba(255, 255, 255, 0.95);
  --panel-border: rgba(226, 232, 240, 0.8);
  --primary: #3b82f6; 
  --primary-hover: #2563eb;
  --primary-light: #93c5fd; 
  --secondary: #1e293b; 
  --text-main: #0f172a;
  --text-muted: #64748b;
  --accent-blue: #38bdf8; 
  --accent-teal: #2dd4bf; 
  --glass-bg: rgba(255, 255, 255, 0.8);
  --glass-border: rgba(255, 255, 255, 0.5);
  --card-shadow: 0 10px 40px -15px rgba(0, 0, 0, 0.08);
  --success: #10b981;
  --warning: #f59e0b;
  --error: #ef4444;
  --card-bg: #ffffff;
  
  /* Backward compatibility for previous classes */
  --bg-light: var(--bg-color);
  --white: #ffffff;
  --navy: var(--secondary);
  --navy-light: #334155;
  --border-light: var(--panel-border);
  --transition: all 0.3s ease;
}

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

html {
    height: 100%;
    overflow: hidden;
}

body {
    font-family: 'Inter', sans-serif;
    background-color: var(--bg-color);
    background-image: 
        radial-gradient(at 0% 0%, rgba(59, 130, 246, 0.08) 0px, transparent 50%),
        radial-gradient(at 100% 100%, rgba(26, 27, 47, 0.05) 0px, transparent 50%);
    background-attachment: fixed;
    color: var(--text-main);
    overflow: hidden;
    height: 100%;
}

/* --- Top Header Logo --- */
.top-header {
    position: fixed;
    top: 2rem;
    left: 4rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 200;
}

.top-logo-img {
    height: 35px;
    width: auto;
}

/* --- Minimal Vertical Navigation (Left) --- */
.minimal-nav {
    position: fixed;
    left: 4rem;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2rem;
    z-index: 100;
}

.nav-line {
    position: absolute;
    left: 12px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border-light);
    z-index: -1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    cursor: pointer;
    text-decoration: none;
    color: var(--text-muted);
    transition: var(--transition);
    position: relative;
    flex-direction: row-reverse;
}

.nav-item span {
    font-weight: 600;
    font-size: 0.9rem;
    opacity: 0.6;
    transition: var(--transition);
}

.nav-dot {
    width: 24px;
    height: 24px;
    background: var(--white);
    border: 2px solid var(--border-light);
    border-radius: 50%;
    transition: var(--transition);
}

.nav-item.active span {
    font-size: 1.25rem;
    color: var(--secondary);
    opacity: 1;
}

.nav-item.active .nav-dot {
    background: var(--primary);
    border-color: var(--primary);
    transform: scale(1.2);
}

/* --- Main Container --- */
.scroll-container {
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    scroll-behavior: smooth;
    scrollbar-gutter: stable;
}

.scroll-container::-webkit-scrollbar {
    width: 8px;
}

.scroll-container::-webkit-scrollbar-track {
    background: transparent;
}

.scroll-container::-webkit-scrollbar-thumb {
    background: rgba(30, 41, 59, 0.1);
    border-radius: 10px;
    border: 2px solid var(--bg-color);
}

.scroll-container::-webkit-scrollbar-thumb:hover {
    background: rgba(30, 41, 59, 0.2);
}

.section {
    min-height: 100vh;
    height: auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 4rem 4rem 4rem 12rem; 
    position: relative;
    background: transparent;
}

.content-wrapper {
    width: 100%;
    max-width: 1400px;
}

/* --- Sections Styling --- */
.badge {
    display: inline-block;
    padding: 6px 14px;
    background: var(--primary-light);
    color: var(--secondary);
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 1rem;
}

h1 {
    font-family: 'Outfit', sans-serif;
    font-size: 4.5rem;
    font-weight: 700;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    color: var(--secondary);
    letter-spacing: -0.02em;
}

h1 .highlight {
    background: linear-gradient(135deg, var(--primary), var(--accent-blue));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    position: relative;
    display: inline-block;
}

h2 {
    font-family: 'Outfit', sans-serif;
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--secondary);
    letter-spacing: -0.01em;
}

.section-desc {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 600px;
    line-height: 1.6;
    margin-bottom: 3rem;
}

/* --- Cards --- */
.grid-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.premium-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    border-radius: 24px;
    padding: 2rem;
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
    box-shadow: 0 10px 30px -5px rgba(30, 41, 59, 0.04);
}

.premium-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 20px 40px -5px rgba(30, 41, 59, 0.08);
    border-color: var(--primary);
}

.card-number {
    font-family: 'Outfit', sans-serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 1rem;
    display: block;
}

.premium-card h3 {
    font-size: 1.2rem;
    margin-bottom: 0.5rem;
    color: var(--secondary);
}

.premium-card p {
    color: var(--text-muted);
    font-size: 0.95rem;
    line-height: 1.5;
}

/* --- Features Section --- */
.features-stack {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    width: 100%;
}

.feature-block {
    background: var(--white);
    border-radius: 16px;
    border: 1px solid rgba(226, 232, 240, 0.8);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03);
    width: 100%;
    overflow: hidden;
}

.feature-block-header {
    padding: 1.5rem;
    border-bottom: 1px solid rgba(226, 232, 240, 0.8);
    background: var(--white);
}

.mac-dots {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 0.75rem;
}

.mac-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: var(--border-light);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.feature-block-header h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 0.25rem;
    font-family: 'Inter', sans-serif;
}

.feature-block-header p {
    font-size: 0.875rem;
    color: var(--text-muted);
}

.video-layout {
    display: flex;
    flex-direction: column;
    padding: 1.5rem;
    gap: 1.5rem;
    background: var(--bg-color);
}

.video-descriptions {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.desc-item {
    background: var(--white);
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid rgba(226, 232, 240, 0.8);
}

.desc-item strong {
    display: block;
    font-size: 0.95rem;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

.desc-item p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.4;
}

.split-view {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    height: 50vh;
}

.view-panel {
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.panel-header {
    background: #f1f5f9;
    padding: 10px 20px;
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--secondary);
    border-bottom: 1px solid var(--border-light);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.panel-content {
    flex-grow: 1;
    overflow-y: auto;
    padding: 0;
    position: relative;
    background: var(--white);
}

#ai-review-content {
    overflow: auto;
    transition: opacity 0.3s ease;
}

#student-img {
    width: 100%;
    display: block;
    transition: opacity 0.3s ease;
}

.subject-tabs {
    display: flex;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.subject-tab {
    background: var(--white);
    border: 1px solid var(--border-light);
    color: var(--text-muted);
    padding: 8px 20px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9rem;
    transition: var(--transition);
}

.subject-tab.active {
    background: var(--secondary);
    color: var(--white);
    border-color: var(--secondary);
}

/* --- Forms --- */
.premium-form {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 2.5rem;
    border-radius: 24px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: var(--card-shadow);
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

label {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

input, select {
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 12px;
    padding: 12px 16px;
    color: var(--secondary);
    font-family: inherit;
    font-size: 1rem;
    transition: var(--transition);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.01);
}

input:focus, select:focus {
    outline: none;
    border-color: var(--primary);
    background: var(--white);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15), inset 0 2px 4px rgba(0, 0, 0, 0.01);
}

.error-field {
    border-color: var(--error) !important;
    background-color: #fff5f5 !important;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1) !important;
}

.subject-chip {
    padding: 10px 20px;
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(226, 232, 240, 0.9);
    backdrop-filter: blur(4px);
    border-radius: 30px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: var(--transition);
}

.subject-chip:hover:not(.disabled) {
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.15);
    transform: translateY(-2px);
}

.subject-chip.selected {
    background: linear-gradient(135deg, var(--primary), var(--primary-hover));
    color: var(--white);
    border-color: transparent;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.subject-chip.disabled {
    opacity: 0.6;
    cursor: help;
    background: rgba(241, 245, 249, 0.5);
    border-style: dashed;
    color: #94a3b8;
}

.pro-badge {
    font-size: 0.65rem;
    background: #E2E8F0;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 8px;
    color: #64748B;
    font-weight: 700;
}

/* --- Calendar & Slots --- */
.calendar-widget {
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    padding: 1.25rem;
}

.cal-nav {
    background: var(--white);
    border: 1px solid var(--border-light);
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calendar-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    border-radius: 8px;
    cursor: pointer;
}

.calendar-day.selected {
    background: var(--secondary) !important;
    color: var(--white) !important;
}

.calendar-day.in-range {
    background: rgba(59, 130, 246, 0.15);
}

.slot {
    padding: 10px;
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    text-align: center;
    cursor: pointer;
}

.slot.selected {
    background: var(--primary);
    border-color: var(--primary);
    color: var(--white);
    font-weight: 700;
}

/* --- Buttons --- */
.btn {
    padding: 14px 28px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: linear-gradient(135deg, var(--secondary), var(--navy-light));
    color: var(--white);
    box-shadow: 0 4px 15px rgba(30, 41, 59, 0.15);
}

.btn-primary:hover {
    background: linear-gradient(135deg, var(--navy-light), var(--secondary));
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(30, 41, 59, 0.25);
}

/* --- Success Overlay --- */
.success-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.5s ease;
}

.success-overlay.active {
    opacity: 1;
    pointer-events: auto;
}

.success-content {
    text-align: center;
    padding: 2rem;
}

.success-content i {
    font-size: 4rem;
    color: var(--success);
    margin-bottom: 1.5rem;
}

/* --- Embedded Panel Adjustments --- */
.panel-content iframe {
    width: 100%;
    height: 100%;
    border: none;
}

/* --- Animations --- */
.anim-fade-up {
    opacity: 0;
}

/* --- Scroll Hint (Right) --- */
.scroll-hint {
    position: absolute;
    bottom: 2rem;
    right: 4rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

/* --- Responsive Adjustments --- */

.meeting-layout {
    display: grid;
    grid-template-columns: 320px 1fr;
    gap: 2rem;
}

@media (max-width: 1024px) {
    .top-header { left: 2rem; top: 1.5rem; }
    .minimal-nav { display: none; }
    .section { padding: 6rem 2rem 2rem 2rem; }
    h1 { font-size: 3rem; }
    .grid-cards { grid-template-columns: 1fr; }
    .split-view { grid-template-columns: 1fr; height: auto; }
    .meeting-layout { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .top-header { left: 1.25rem; top: 1.25rem; }
    .section { padding: 5rem 1rem 2rem 1rem; }
    h1 { font-size: 2.2rem; margin-bottom: 1rem; }
    h2 { font-size: 1.8rem; margin-bottom: 0.75rem; }
    .section-desc { font-size: 1rem; margin-bottom: 2rem; }
    .premium-card { padding: 1.5rem; }
    .premium-form { padding: 1.5rem; }
    .form-row { grid-template-columns: 1fr; gap: 1rem; margin-bottom: 1rem; }
    
    .subject-tabs { flex-wrap: wrap; }
    .subject-tab { flex: 1 1 auto; text-align: center; font-size: 0.85rem; padding: 8px 12px; }
    
    .scroll-hint { display: none; }
    .btn { width: 100%; text-align: center; margin-bottom: 0.5rem; }
    
    .feature-block-header { padding: 1.25rem; }
    .video-layout { padding: 1.25rem; }
    .video-descriptions { grid-template-columns: 1fr; }
    
    .panel-header { padding: 8px 12px; font-size: 0.75rem; }
    
    .roles-container { margin-top: 2rem; gap: 1.5rem; }
    .role-block { padding: 1.5rem; gap: 1.5rem; }
    .role-title { font-size: 1.5rem; margin-bottom: 1rem; }
    .role-icon { width: 3rem; height: 3rem; font-size: 1.25rem; margin-bottom: 1rem; }
    
    .success-content i { font-size: 3rem; }
    .success-content h2 { font-size: 1.5rem; }
}

@media (max-width: 480px) {
    h1 { font-size: 1.8rem; }
    h2 { font-size: 1.5rem; }
    .premium-card { padding: 1.25rem; }
    .premium-form { padding: 1.25rem; }
    .calendar-widget { padding: 1rem; }
    .feature-block-content { padding: 1rem !important; }
}

/* Support for smooth horizontal scroll in calendars specifically for mobile */
.calendar-scroll-area {
    display: flex;
    gap: 2rem;
    overflow-x: auto;
    padding-bottom: 0.5rem;
    scroll-snap-type: x mandatory;
    -webkit-overflow-scrolling: touch;
}
.calendar-month-grid {
    scroll-snap-align: start;
}
