/* ==========================================================================
   Yakhto Platform (منصة يخطو) - Core Design System & Styling
   ========================================================================== */

/* Font & CSS Variables Design System */
:root {
    /* Color Palette (Light Mode Default) */
    --primary: #0d9488;          /* Vibrant Emerald Teal */
    --primary-hover: #0f766e;
    --primary-light: #ccfbf1;
    --secondary: #6366f1;        /* Modern Indigo */
    --secondary-hover: #4f46e5;
    --accent: #f59e0b;           /* Amber Gold Accent */
    
    --bg-main: #f8fafc;
    --bg-card: #ffffff;
    --bg-glass: rgba(255, 255, 255, 0.85);
    --border-color: #e2e8f0;
    --border-hover: #cbd5e1;
    
    --text-main: #0f172a;
    --text-muted: #64748b;
    --text-inverse: #ffffff;
    
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 25px -5px rgba(13, 148, 136, 0.15), 0 8px 10px -6px rgba(0, 0, 0, 0.05);
    --shadow-glow: 0 0 30px rgba(13, 148, 136, 0.25);
    
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 24px;
    --radius-full: 9999px;
    
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --font-family: 'Cairo', 'Tajawal', system-ui, -apple-system, sans-serif;
}

/* Dark Theme Overrides */
[data-theme="dark"] {
    --bg-main: #0b1324;
    --bg-card: #152035;
    --bg-glass: rgba(21, 32, 53, 0.85);
    --border-color: #1e293b;
    --border-hover: #334155;
    
    --text-main: #f1f5f9;
    --text-muted: #94a3b8;
    
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 35px rgba(13, 148, 136, 0.35);
}

/* Base & Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

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

body {
    font-family: var(--font-family);
    background-color: var(--bg-main);
    color: var(--text-main);
    line-height: 1.7;
    direction: rtl;
    text-align: right;
    overflow-x: hidden;
    transition: background-color 0.4s ease, color 0.4s ease;
}

a {
    color: inherit;
    text-decoration: none;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img, svg {
    display: block;
    max-width: 100%;
}

/* Typography Utilities */
h1, h2, h3, h4, h5, h6 {
    font-weight: 800;
    line-height: 1.3;
    color: var(--text-main);
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-name {
    color: var(--primary);
    position: relative;
    display: inline-block;
}

.text-center { text-align: center; }
.margin-v { margin: 2rem 0; }

/* Containers & Grid Layouts */
.container {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.5rem; }

/* Buttons & Badges */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.75rem 1.6rem;
    font-family: var(--font-family);
    font-size: 1rem;
    font-weight: 700;
    border-radius: var(--radius-md);
    cursor: pointer;
    border: 2px solid transparent;
    transition: var(--transition);
    white-space: nowrap;
}

.btn-sm { padding: 0.4rem 1rem; font-size: 0.875rem; }
.btn-lg { padding: 1rem 2.2rem; font-size: 1.1rem; }
.btn-block { width: 100%; }

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, #0f766e 100%);
    color: var(--text-inverse);
    box-shadow: 0 4px 14px rgba(13, 148, 136, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(13, 148, 136, 0.45);
    background: linear-gradient(135deg, #0f766e 0%, #115e59 100%);
}

.btn-outline {
    background: transparent;
    border-color: var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: var(--text-inverse);
    transform: translateY(-2px);
}

.btn-glass {
    background: var(--bg-glass);
    backdrop-filter: blur(10px);
    border-color: var(--border-color);
    color: var(--text-main);
}

.btn-glass:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px);
}

.shadow-btn {
    box-shadow: 0 10px 25px -5px rgba(13, 148, 136, 0.4);
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 1rem;
    background: var(--primary-light);
    color: var(--primary-hover);
    border-radius: var(--radius-full);
    font-size: 0.9rem;
    font-weight: 700;
    border: 1px solid rgba(13, 148, 136, 0.2);
}

[data-theme="dark"] .badge {
    background: rgba(13, 148, 136, 0.15);
    color: #5eead4;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    background-color: var(--primary);
    border-radius: 50%;
    animation: pulse 1.8s infinite;
}

@keyframes pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(13, 148, 136, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(13, 148, 136, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(13, 148, 136, 0); }
}

.section-badge {
    display: inline-block;
    padding: 0.3rem 0.9rem;
    background: var(--primary-light);
    color: var(--primary);
    font-size: 0.85rem;
    font-weight: 800;
    border-radius: var(--radius-full);
    margin-bottom: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

[data-theme="dark"] .section-badge {
    background: rgba(13, 148, 136, 0.2);
    color: #5eead4;
}

.section-title {
    font-size: 2.3rem;
    margin-bottom: 1rem;
}

.section-subtitle {
    font-size: 1.15rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto 3rem auto;
}

/* Header & Navigation Bar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: var(--bg-glass);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border-color);
    transition: var(--transition);
}

.nav-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.logo-icon {
    width: 44px;
    height: 44px;
    color: var(--primary);
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.brand-title {
    font-size: 1.4rem;
    font-weight: 900;
    letter-spacing: -0.5px;
}

.brand-title .highlight {
    color: var(--primary);
}

.brand-subtitle {
    font-size: 0.7rem;
    color: var(--text-muted);
    letter-spacing: 1px;
    text-transform: uppercase;
    margin-top: -4px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 1.8rem;
}

.nav-links a {
    font-weight: 600;
    color: var(--text-muted);
    font-size: 0.95rem;
    position: relative;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--primary);
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -6px;
    right: 0;
    width: 0;
    height: 3px;
    background: var(--primary);
    border-radius: var(--radius-full);
    transition: var(--transition);
}

.nav-links a:hover::after, .nav-links a.active::after {
    width: 100%;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.theme-toggle {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-main);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: var(--transition);
}

.theme-toggle:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: rotate(15deg);
}

[data-theme="dark"] .sun-icon { display: block; }
[data-theme="dark"] .moon-icon { display: none; }
[data-theme="light"] .sun-icon { display: none; }
[data-theme="light"] .moon-icon { display: block; }

.mobile-menu-btn {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
}

.mobile-menu-btn span {
    width: 25px;
    height: 3px;
    background-color: var(--text-main);
    border-radius: 3px;
    transition: var(--transition);
}

/* Hero Section */
.hero {
    position: relative;
    padding: 160px 0 100px 0;
    overflow: hidden;
}

.hero-bg-shapes .shape {
    position: absolute;
    border-radius: 50%;
    filter: blur(90px);
    opacity: 0.4;
    z-index: -1;
}

.shape-1 {
    top: 10%;
    right: -5%;
    width: 450px;
    height: 450px;
    background: rgba(13, 148, 136, 0.35);
}

.shape-2 {
    bottom: 5%;
    left: -5%;
    width: 400px;
    height: 400px;
    background: rgba(99, 102, 241, 0.25);
}

.shape-3 {
    top: 50%;
    right: 40%;
    width: 300px;
    height: 300px;
    background: rgba(245, 158, 11, 0.15);
}

.hero-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4rem;
}

.hero-content {
    text-align: center;
    max-width: 900px;
}

.hero-title {
    font-size: 3.2rem;
    font-weight: 900;
    margin: 1.5rem 0;
    letter-spacing: -1px;
}

.hero-description {
    font-size: 1.3rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    line-height: 1.8;
}

.hero-buttons {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.2rem;
    margin-bottom: 3.5rem;
    flex-wrap: wrap;
}

.hero-stats {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 1.8rem 2rem;
    box-shadow: var(--shadow-lg);
}

.stat-card {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: row;
    gap: 0.2rem;
    flex-wrap: wrap;
}

.stat-num {
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--primary);
}

.stat-plus {
    font-size: 1.8rem;
    font-weight: 900;
    color: var(--secondary);
}

.stat-label {
    width: 100%;
    font-size: 0.88rem;
    color: var(--text-muted);
    font-weight: 600;
}

/* Dashboard Mockup Visual */
.hero-visual {
    width: 100%;
    max-width: 1050px;
}

.mockup-window {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-glow), var(--shadow-lg);
    overflow: hidden;
    transition: var(--transition);
}

.mockup-header {
    background: var(--bg-main);
    padding: 0.8rem 1.2rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.dots {
    display: flex;
    gap: 6px;
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
}

.dot.red { background-color: #ff5f56; }
.dot.yellow { background-color: #ffbd2e; }
.dot.green { background-color: #27c93f; }

.url-bar {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    padding: 0.25rem 1rem;
    font-size: 0.8rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-grow: 1;
    max-width: 350px;
}

.mockup-body {
    display: grid;
    grid-template-columns: 240px 1fr;
    min-height: 380px;
}

.dashboard-sidebar {
    background: rgba(13, 148, 136, 0.03);
    border-left: 1px solid var(--border-color);
    padding: 1.5rem 1rem;
}

.user-chip {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
}

.avatar {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
}

.user-info {
    display: flex;
    flex-direction: column;
}

.user-name { font-size: 0.88rem; font-weight: 700; }
.user-role { font-size: 0.75rem; color: var(--text-muted); }

.dash-menu li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.7rem 0.9rem;
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    border-radius: var(--radius-sm);
    cursor: pointer;
    margin-bottom: 0.4rem;
    transition: var(--transition);
}

.dash-menu li:hover, .dash-menu li.active {
    background: var(--primary-light);
    color: var(--primary-hover);
}

[data-theme="dark"] .dash-menu li:hover, [data-theme="dark"] .dash-menu li.active {
    background: rgba(13, 148, 136, 0.2);
    color: #5eead4;
}

.dashboard-main {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

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

.dash-top-bar h3 { font-size: 1.1rem; }

.status-badge {
    padding: 0.25rem 0.75rem;
    font-size: 0.78rem;
    border-radius: var(--radius-full);
    font-weight: 700;
}

.status-badge.success {
    background: #dcfce7;
    color: #166534;
}

[data-theme="dark"] .status-badge.success {
    background: rgba(22, 101, 52, 0.3);
    color: #86efac;
}

.dash-widgets {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 1rem;
}

.widget {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1rem;
}

.widget-title {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.progress-circle-wrap {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 0.5rem;
}

.progress-text {
    position: absolute;
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--primary);
}

.info-widget {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    justify-content: center;
}

.info-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
}

.info-row span { color: var(--text-muted); }
.text-emerald { color: #10b981; }

.dash-recent-activity h4 {
    font-size: 0.9rem;
    margin-bottom: 0.6rem;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 0.75rem;
}

.act-icon {
    width: 32px;
    height: 32px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.act-details p { font-size: 0.85rem; font-weight: 600; }
.act-time { font-size: 0.75rem; color: var(--text-muted); }

/* Section Base */
.section {
    padding: 90px 0;
}

/* Workflow Section (كيف نقدم الخدمة) */
.workflow-section {
    background: linear-gradient(180deg, var(--bg-main) 0%, rgba(13, 148, 136, 0.04) 50%, var(--bg-main) 100%);
}

.workflow-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    position: relative;
    transition: var(--transition);
    display: flex;
    flex-direction: column;
}

.workflow-card:hover {
    transform: translateY(-8px);
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
}

.step-num {
    position: absolute;
    top: 1rem;
    left: 1rem;
    font-size: 2.2rem;
    font-weight: 900;
    color: var(--border-hover);
    opacity: 0.6;
}

.card-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-light), rgba(13, 148, 136, 0.3));
    color: var(--primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.workflow-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.8rem;
}

.workflow-card p {
    font-size: 0.95rem;
    color: var(--text-muted);
    margin-bottom: 1.2rem;
    flex-grow: 1;
}

.check-list li {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
}

.check-list li::before {
    content: '✓';
    color: var(--primary);
    font-weight: 900;
}

/* Responsibilities Box */
.responsibilities-box {
    margin-top: 5rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-md);
}

.resp-header {
    text-align: center;
    margin-bottom: 2rem;
}

.resp-header h3 { font-size: 1.5rem; }
.resp-header p { color: var(--text-muted); font-size: 0.95rem; }

.resp-column {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.5rem;
}

.column-badge {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: #e2e8f0;
    color: #334155;
    font-size: 0.85rem;
    font-weight: 800;
    border-radius: var(--radius-sm);
    margin-bottom: 1.2rem;
}

.badge-primary { background: var(--primary); color: #fff; }
.badge-secondary { background: var(--secondary); color: #fff; }

.resp-column ul li {
    font-size: 0.9rem;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: flex-start;
    gap: 0.5rem;
}

.resp-column ul li svg {
    flex-shrink: 0;
    margin-top: 4px;
    color: var(--primary);
}

/* Section 2: Beneficiaries Perspective (كيف يستفيد المستفيد؟) */
.tabs-container {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    box-shadow: var(--shadow-lg);
}

.tabs-header {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1.5rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
}

.tab-btn {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.75rem 1.4rem;
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--text-muted);
    font-family: var(--font-family);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
}

.tab-btn:hover, .tab-btn.active {
    background: var(--primary);
    color: var(--text-inverse);
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(13, 148, 136, 0.3);
}

.tab-pane {
    display: none;
    animation: fadeIn 0.4s ease;
}

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

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

.pane-text .sub-badge {
    display: inline-block;
    color: var(--primary);
    font-weight: 800;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.pane-text h3 { font-size: 1.6rem; margin-bottom: 1rem; }
.pane-text p { color: var(--text-muted); font-size: 1.05rem; margin-bottom: 1.5rem; }

.benefit-features li {
    font-size: 0.98rem;
    margin-bottom: 0.8rem;
    line-height: 1.6;
}

.benefit-features li strong { color: var(--primary); }

.pane-card-box {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.pane-card-box .box-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.pane-card-box h4 {
    font-size: 1.2rem;
    margin-bottom: 1.2rem;
}

.mini-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.m-stat {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 1rem;
    border-radius: var(--radius-sm);
    display: flex;
    flex-direction: column;
}

.m-stat span { font-size: 0.78rem; color: var(--text-muted); }
.m-stat strong { font-size: 1.1rem; color: var(--primary); }

.spec-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
}

.pill {
    padding: 0.4rem 0.9rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-main);
}

.family-mockup {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.2rem;
}

.fam-header {
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 0.8rem;
    margin-bottom: 1rem;
}

.fam-title { font-weight: 800; font-size: 0.95rem; }
.fam-status { font-size: 0.75rem; color: #10b981; }

.fam-card {
    background: var(--primary-light);
    padding: 1rem;
    border-radius: var(--radius-sm);
    color: var(--text-main);
}

[data-theme="dark"] .fam-card {
    background: rgba(13, 148, 136, 0.2);
}

.fam-card .tag {
    font-size: 0.75rem;
    font-weight: 800;
    color: var(--primary);
    margin-bottom: 0.3rem;
}

.fam-card p { font-size: 0.88rem; font-weight: 600; margin-bottom: 0.8rem; }

.fam-btn {
    background: var(--primary);
    color: #fff;
    border: none;
    padding: 0.3rem 0.8rem;
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
}

/* Section 3: Metrics & Assessment Tools (المقاييس والمناهج) */
.filter-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    margin-bottom: 2.5rem;
    flex-wrap: wrap;
}

.filter-btn {
    padding: 0.6rem 1.2rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-full);
    color: var(--text-muted);
    font-family: var(--font-family);
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.filter-btn:hover, .filter-btn.active {
    background: var(--primary);
    color: #fff;
    border-color: var(--primary);
}

.metric-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2rem;
    display: flex;
    flex-direction: column;
    position: relative;
    transition: var(--transition);
}

.metric-card:hover {
    transform: translateY(-6px);
    border-color: var(--primary);
    box-shadow: var(--shadow-lg);
}

.m-card-badge {
    position: absolute;
    top: 1.2rem;
    left: 1.2rem;
    font-size: 0.75rem;
    font-weight: 800;
    padding: 0.2rem 0.7rem;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: var(--radius-full);
}

[data-theme="dark"] .m-card-badge {
    background: rgba(13, 148, 136, 0.2);
    color: #5eead4;
}

.badge-gold {
    background: #fef3c7 !important;
    color: #b45309 !important;
}

.m-icon { font-size: 2.4rem; margin-bottom: 1.2rem; }

.metric-card h3 { font-size: 1.25rem; margin-bottom: 0.8rem; }
.m-desc { font-size: 0.95rem; color: var(--text-muted); margin-bottom: 1.5rem; flex-grow: 1; }

.m-footer { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.m-tag { font-size: 0.75rem; font-weight: 700; padding: 0.2rem 0.6rem; background: var(--bg-main); border: 1px solid var(--border-color); border-radius: var(--radius-sm); }

.highlight-card {
    border: 2px solid var(--accent);
    background: linear-gradient(135deg, var(--bg-card) 0%, rgba(245, 158, 11, 0.05) 100%);
}

.tag-gold {
    background: #fffbeb;
    border-color: #fde68a;
    color: #b45309;
}

/* Section 4: Interactive IEP Demo (مولد الخطة الفردية) */
.iep-builder-box {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
}

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

.control-group label {
    font-weight: 700;
    font-size: 0.95rem;
}

.custom-select, input[type="text"], input[type="tel"], input[type="email"], textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    font-family: var(--font-family);
    font-size: 0.95rem;
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-main);
    outline: none;
    transition: var(--transition);
}

.custom-select:focus, input:focus, textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(13, 148, 136, 0.15);
}

.iep-result-card {
    background: var(--bg-main);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 1.8rem;
    margin-top: 2rem;
    display: none;
}

.iep-result-card.show {
    display: block;
    animation: fadeIn 0.4s ease;
}

.result-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.plan-id { font-size: 0.78rem; font-weight: 800; color: var(--primary); }
.plan-actions { display: flex; gap: 0.6rem; }

.iep-table-wrap {
    overflow-x: auto;
}

.iep-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.iep-table th, .iep-table td {
    padding: 0.9rem 1rem;
    text-align: right;
    border-bottom: 1px solid var(--border-color);
}

.iep-table th {
    background: var(--bg-card);
    font-weight: 800;
    color: var(--text-main);
}

.iep-table tr:hover {
    background: rgba(13, 148, 136, 0.03);
}

.goal-code {
    font-family: monospace;
    font-weight: 700;
    color: var(--primary);
    background: var(--primary-light);
    padding: 0.2rem 0.5rem;
    border-radius: var(--radius-sm);
}

[data-theme="dark"] .goal-code {
    background: rgba(13, 148, 136, 0.2);
}

.result-footer {
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Section 5: Matrix Comparison Table */
.matrix-table-wrap {
    overflow-x: auto;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

.matrix-table {
    width: 100%;
    border-collapse: collapse;
}

.matrix-table th, .matrix-table td {
    padding: 1.2rem;
    text-align: right;
    border-bottom: 1px solid var(--border-color);
    font-size: 0.95rem;
}

.matrix-table th {
    background: var(--bg-main);
    font-weight: 800;
}

.check-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--primary-light);
    color: var(--primary);
    border-radius: 50%;
    font-weight: 900;
    font-size: 0.8rem;
}

/* Section 6: Pricing Card & Proposal */
.pricing-card-box {
    background: var(--bg-card);
    border: 2px solid var(--primary);
    border-radius: var(--radius-lg);
    padding: 3rem 2.5rem;
    position: relative;
    box-shadow: var(--shadow-glow), var(--shadow-lg);
    max-width: 950px;
    margin: 0 auto;
}

.ribbon {
    position: absolute;
    top: -15px;
    right: 30px;
    background: linear-gradient(135deg, var(--accent), #d97706);
    color: #fff;
    font-weight: 800;
    font-size: 0.85rem;
    padding: 0.3rem 1.2rem;
    border-radius: var(--radius-full);
    box-shadow: 0 4px 10px rgba(245, 158, 11, 0.4);
}

.pricing-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-color);
    padding-bottom: 2rem;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.p-title-wrap h3 { font-size: 1.8rem; margin-bottom: 0.5rem; }
.p-title-wrap p { color: var(--text-muted); font-size: 1rem; }

.price-tag-wrap {
    text-align: left;
}

.old-price {
    font-size: 1.2rem;
    color: var(--text-muted);
    text-decoration: line-through;
    font-weight: 700;
}

.current-price {
    display: flex;
    align-items: flex-start;
    gap: 0.2rem;
    color: var(--primary);
    line-height: 1;
}

.current-price .currency { font-size: 1.8rem; font-weight: 800; margin-top: 6px; }
.current-price .amount { font-size: 3.5rem; font-weight: 900; }
.current-price .period { font-size: 1rem; color: var(--text-muted); align-self: flex-end; margin-bottom: 8px; }

.discount-badge {
    display: inline-block;
    font-size: 0.75rem;
    font-weight: 800;
    color: #166534;
    background: #dcfce7;
    padding: 0.2rem 0.6rem;
    border-radius: var(--radius-sm);
    margin-top: 4px;
}

.pricing-features-grid {
    margin-bottom: 2.5rem;
}

.pf-column h4 {
    font-size: 1.1rem;
    margin-bottom: 1rem;
    color: var(--text-main);
}

.pf-column ul li {
    font-size: 0.95rem;
    margin-bottom: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

.validity-note {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 1rem;
}

/* Section 7: Booking Form Section */
.booking-section {
    background: linear-gradient(180deg, var(--bg-main) 0%, rgba(99, 102, 241, 0.04) 100%);
}

.booking-wrapper {
    align-items: center;
    gap: 3rem;
}

.booking-info h2 { font-size: 2.2rem; margin-bottom: 1.2rem; }
.booking-info p { color: var(--text-muted); font-size: 1.1rem; margin-bottom: 2rem; }

.contact-details-box {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.c-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    padding: 1rem 1.2rem;
    border-radius: var(--radius-md);
}

.c-icon { font-size: 1.8rem; }
.c-item span { display: block; font-size: 0.8rem; color: var(--text-muted); }
.c-item strong { font-size: 1rem; color: var(--text-main); }

.booking-form-box {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow-lg);
}

.booking-form-box h3 { font-size: 1.4rem; margin-bottom: 1.5rem; }

.form-group {
    margin-bottom: 1.2rem;
}

.form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 700;
    margin-bottom: 0.4rem;
}

.form-row {
    gap: 1rem;
}

/* Footer */
.footer {
    background: #090f1d;
    color: #94a3b8;
    padding: 80px 0 30px 0;
    border-top: 1px solid #1e293b;
}

.footer .brand-title { color: #f8fafc; }
.footer p { font-size: 0.9rem; margin-top: 1rem; line-height: 1.7; }

.footer-links h4, .footer-newsletter h4 {
    color: #f8fafc;
    font-size: 1.1rem;
    margin-bottom: 1.2rem;
}

.footer-links ul li {
    margin-bottom: 0.6rem;
}

.footer-links ul li a {
    color: #94a3b8;
    font-size: 0.9rem;
}

.footer-links ul li a:hover {
    color: var(--primary);
}

.newsletter-input-group {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.newsletter-input-group input {
    background: #152035;
    border-color: #1e293b;
    color: #fff;
}

.footer-bottom {
    border-top: 1px solid #1e293b;
    margin-top: 4rem;
    padding-top: 2rem;
    text-align: center;
    font-size: 0.88rem;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    bottom: 2rem;
    left: 2rem;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.toast {
    background: var(--bg-card);
    color: var(--text-main);
    border: 1px solid var(--border-color);
    border-right: 4px solid var(--primary);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    font-size: 0.95rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    animation: slideInLeft 0.3s ease;
}

@keyframes slideInLeft {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}

/* Responsive Media Queries & Mobile UX Enhancements */
@media (max-width: 1024px) {
    .hero-title { font-size: 2.5rem; }
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: repeat(2, 1fr); }
    .mockup-body { grid-template-columns: 1fr; }
    .dashboard-sidebar { display: none; }
    .booking-wrapper { grid-template-columns: 1fr; }
    .iep-controls { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    .container {
        padding: 0 1.2rem;
    }

    .section {
        padding: 60px 0;
    }

    .nav-links {
        position: fixed;
        top: 80px;
        left: 0;
        right: 0;
        background: var(--bg-card);
        flex-direction: column;
        align-items: stretch;
        padding: 2rem 1.5rem;
        border-bottom: 2px solid var(--primary);
        box-shadow: var(--shadow-lg);
        clip-path: circle(0% at 100% 0);
        transition: clip-path 0.4s ease-in-out;
        z-index: 999;
    }
    
    .nav-links.mobile-open {
        clip-path: circle(140% at 100% 0);
    }

    .nav-links a {
        padding: 0.8rem 1rem;
        font-size: 1.1rem;
        border-radius: var(--radius-sm);
        border-bottom: 1px solid var(--border-color);
    }
    
    .mobile-menu-btn { display: flex; }

    .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; gap: 1.2rem; }

    .hero {
        padding: 120px 0 60px 0;
    }

    .hero-title {
        font-size: 2.1rem;
        line-height: 1.4;
    }

    .hero-description {
        font-size: 1.1rem;
        margin-bottom: 1.8rem;
    }

    .hero-buttons {
        flex-direction: column;
        width: 100%;
    }

    .hero-buttons .btn {
        width: 100%;
        min-height: 52px;
    }

    .hero-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 1.2rem;
        padding: 1.2rem;
    }

    .stat-num { font-size: 1.8rem; }
    .stat-label { font-size: 0.8rem; }

    /* Scrollable Tabs for Mobile */
    .tabs-header {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 1rem;
        -webkit-overflow-scrolling: touch;
        scroll-snap-type: x mandatory;
    }

    .tab-btn {
        scroll-snap-align: start;
        flex-shrink: 0;
        min-height: 48px;
        padding: 0.6rem 1.2rem;
        font-size: 0.95rem;
    }

    .tabs-container {
        padding: 1.2rem;
    }

    .pane-text h3 {
        font-size: 1.35rem;
    }

    /* Scrollable Metrics Filter Bar for Mobile */
    .filter-bar {
        flex-wrap: nowrap;
        overflow-x: auto;
        justify-content: flex-start;
        padding-bottom: 0.8rem;
        -webkit-overflow-scrolling: touch;
    }

    .filter-btn {
        flex-shrink: 0;
        min-height: 44px;
    }

    /* Pricing Mobile Adjustments */
    .pricing-card-box {
        padding: 2rem 1.2rem;
    }

    .ribbon {
        right: 50%;
        transform: translateX(50%);
        font-size: 0.8rem;
    }

    .pricing-header {
        flex-direction: column;
        text-align: center;
    }

    .price-tag-wrap {
        text-align: center;
    }

    .current-price .amount {
        font-size: 2.8rem;
    }

    /* Booking Form Mobile UX */
    .booking-form-box {
        padding: 1.5rem 1.2rem;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    input, select, textarea, .btn {
        min-height: 48px;
    }

    /* Toast Notification for Mobile */
    .toast-container {
        left: 1rem;
        right: 1rem;
        bottom: 1rem;
    }

    .toast {
        font-size: 0.88rem;
        padding: 0.8rem 1rem;
    }
}

@media (max-width: 480px) {
    .hero-title {
        font-size: 1.8rem;
    }

    .section-title {
        font-size: 1.6rem;
    }

    .hero-stats {
        grid-template-columns: 1fr;
    }

    .mini-stats-grid {
        grid-template-columns: 1fr;
    }
}

