/* ITTR.net - Main Stylesheet
   Colors: White bg, Blue (#2563eb / #1a5276), Maroon (#7b1a2b)
   Framework: Custom (no Bootstrap)
*/

/* ============ BASE ============ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --primary: #2563eb;
    --primary-dark: #1a5276;
    --primary-light: #dbeafe;
    --accent: #7b1a2b;
    --accent-light: #fce7f3;
    --accent-dark: #5c1320;
    --bg: #ffffff;
    --bg-gray: #f8fafc;
    --bg-section: #f1f5f9;
    --text: #1f2937;
    --text-light: #6b7280;
    --border: #e5e7eb;
    --success: #059669;
    --error: #dc2626;
    --warning: #d97706;
    --shadow: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    --shadow-xl: 0 20px 60px rgba(0,0,0,0.15);
    --radius: 8px;
    --radius-lg: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; }
body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    color: var(--text);
    background: var(--bg);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-dark); }
img { max-width: 100%; height: auto; }
.container { max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ============ BUTTONS ============ */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 12px 28px; border-radius: var(--radius);
    font-weight: 600; font-size: 15px;
    transition: var(--transition); cursor: pointer;
    border: 2px solid transparent; text-decoration: none;
    position: relative; overflow: hidden;
}
.btn::after {
    content: '';
    position: absolute; inset: 0;
    background: rgba(255,255,255,0.15);
    transform: translateX(-100%);
    transition: var(--transition);
}
.btn:hover::after { transform: translateX(0); }

.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dark); color: white; transform: translateY(-2px); box-shadow: 0 8px 25px rgba(37,99,235,0.3); }

.btn-accent { background: var(--accent); color: white; }
.btn-accent:hover { background: var(--accent-dark); color: white; transform: translateY(-2px); box-shadow: 0 8px 25px rgba(123,26,43,0.3); }

.btn-outline { background: transparent; border-color: var(--primary); color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: white; transform: translateY(-2px); }

.btn-white { background: white; color: var(--primary); }
.btn-white:hover { background: var(--bg-gray); transform: translateY(-2px); box-shadow: var(--shadow-lg); }

.btn-sm { padding: 8px 18px; font-size: 13px; }
.btn-lg { padding: 16px 36px; font-size: 17px; }

/* ============ NAVIGATION ============ */
nav {
    position: fixed; top: 0; left: 0; right: 0;
    z-index: 1000; padding: 0 20px;
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
    transition: var(--transition);
}
nav.scrolled { box-shadow: var(--shadow); }
.nav-inner {
    max-width: 1200px; margin: 0 auto;
    display: flex; align-items: center; justify-content: space-between;
    height: 70px;
}
.nav-logo {
    display: flex; align-items: center; gap: 10px;
    font-size: 24px; font-weight: 800; color: var(--primary-dark);
}
.nav-logo span { color: var(--accent); }
.nav-links { display: flex; align-items: center; gap: 32px; list-style: none; }
.nav-links a {
    color: var(--text); font-weight: 500; font-size: 15px;
    position: relative; padding: 4px 0;
}
.nav-links a::after {
    content: ''; position: absolute; bottom: 0; left: 0;
    width: 0; height: 2px; background: var(--primary);
    transition: var(--transition);
}
.nav-links a:hover::after, .nav-links a.active::after { width: 100%; }
.nav-links a:hover { color: var(--primary); }

.mobile-toggle { display: none; flex-direction: column; gap: 5px; cursor: pointer; padding: 5px; }
.mobile-toggle span {
    display: block; width: 25px; height: 2px; background: var(--text);
    transition: var(--transition);
}

/* ============ HERO ============ */
.hero {
    position: relative;
    min-height: 85vh; display: flex; align-items: center;
    background: linear-gradient(135deg, var(--primary-dark) 0%, #0f3b5e 50%, var(--accent) 100%);
    padding: 120px 0 80px; overflow: hidden;
}
.hero::before {
    content: ''; position: absolute; inset: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}
.hero-content {
    position: relative; z-index: 2;
    text-align: center; color: white; max-width: 800px; margin: 0 auto;
}
.hero h1 {
    font-size: 56px; font-weight: 800; line-height: 1.1;
    margin-bottom: 20px; letter-spacing: -1px;
}
.hero h1 span { color: #fbbf24; }
.hero p {
    font-size: 20px; opacity: 0.9; line-height: 1.7;
    margin-bottom: 40px; max-width: 600px; margin-left: auto; margin-right: auto;
}
.hero-cta { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.hero-stats {
    display: flex; justify-content: center; gap: 60px; margin-top: 60px;
}
.hero-stat { text-align: center; }
.hero-stat-number { font-size: 36px; font-weight: 800; color: #fbbf24; display: block; }
.hero-stat-label { font-size: 14px; opacity: 0.8; text-transform: uppercase; letter-spacing: 1px; }

/* ============ SECTIONS ============ */
.section { padding: 100px 0; }
.section-gray { background: var(--bg-section); }
.section-header { text-align: center; margin-bottom: 60px; }
.section-header h2 {
    font-size: 36px; font-weight: 800; color: var(--primary-dark);
    margin-bottom: 12px;
}
.section-header h2 span { color: var(--accent); }
.section-header p { color: var(--text-light); font-size: 18px; max-width: 600px; margin: 0 auto; }

/* ============ FEATURES GRID ============ */
.features-grid {
    display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px;
}
.feature-card {
    background: white; border-radius: var(--radius-lg); padding: 40px 30px;
    text-align: center; transition: var(--transition);
    border: 1px solid var(--border); position: relative; overflow: hidden;
}
.feature-card::before {
    content: ''; position: absolute; top: 0; left: 0; right: 0;
    height: 4px; background: var(--primary);
    transform: scaleX(0); transition: var(--transition);
}
.feature-card:hover {
    transform: translateY(-8px); box-shadow: var(--shadow-xl);
}
.feature-card:hover::before { transform: scaleX(1); }
.feature-icon {
    width: 72px; height: 72px; margin: 0 auto 20px;
    background: var(--primary-light); border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 28px;
}
.feature-card h3 { font-size: 20px; color: var(--primary-dark); margin-bottom: 10px; }
.feature-card p { color: var(--text-light); font-size: 15px; line-height: 1.7; }

/* ============ HOW IT WORKS ============ */
.steps { display: flex; gap: 30px; counter-reset: step; }
.step {
    flex: 1; text-align: center; position: relative; padding: 40px 20px;
}
.step::after {
    content: ''; position: absolute; top: 55px; left: 60%;
    width: 80%; height: 2px; background: linear-gradient(to right, var(--primary), transparent);
}
.step:last-child::after { display: none; }
.step-number {
    width: 70px; height: 70px; margin: 0 auto 20px;
    background: var(--primary); color: white; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 24px; font-weight: 800;
    position: relative; z-index: 2;
}
.step h3 { font-size: 18px; color: var(--primary-dark); margin-bottom: 8px; }
.step p { color: var(--text-light); font-size: 15px; }

/* ============ TESTIMONIALS ============ */
.testimonials { display: grid; grid-template-columns: repeat(3, 1fr); gap: 30px; }
.testimonial-card {
    background: white; border-radius: var(--radius-lg); padding: 35px;
    border: 1px solid var(--border);
}
.testimonial-stars { color: #f59e0b; margin-bottom: 15px; font-size: 18px; }
.testimonial-text { color: var(--text-light); font-size: 15px; line-height: 1.7; margin-bottom: 20px; font-style: italic; }
.testimonial-author { display: flex; align-items: center; gap: 12px; }
.testimonial-avatar {
    width: 48px; height: 48px; border-radius: 50%; 
    background: var(--primary-light); display: flex; align-items: center; justify-content: center;
    font-weight: 700; color: var(--primary); font-size: 18px;
}
.testimonial-name { font-weight: 600; color: var(--text); }
.testimonial-role { font-size: 13px; color: var(--text-light); }

/* ============ CTA ============ */
.cta-section {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--accent) 100%);
    color: white; text-align: center; padding: 80px 0;
}
.cta-section h2 { font-size: 40px; font-weight: 800; margin-bottom: 15px; }
.cta-section p { font-size: 18px; opacity: 0.9; margin-bottom: 35px; }

/* ============ FOOTER ============ */
footer {
    background: #0f172a; color: rgba(255,255,255,0.7);
    padding: 60px 0 30px;
}
.footer-grid { 
    display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px;
    margin-bottom: 40px;
}
.footer-brand h3 { color: white; font-size: 22px; margin-bottom: 12px; }
.footer-brand h3 span { color: var(--accent); }
.footer-brand p { font-size: 14px; line-height: 1.7; }
.footer-col h4 { color: white; font-size: 16px; margin-bottom: 16px; }
.footer-col a {
    display: block; color: rgba(255,255,255,0.6); font-size: 14px;
    margin-bottom: 10px; transition: var(--transition);
}
.footer-col a:hover { color: white; padding-left: 5px; }
.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px; text-align: center;
    font-size: 14px;
}

/* ============ FORMS ============ */
.form-group { margin-bottom: 20px; }
.form-label { display: block; font-weight: 600; font-size: 14px; color: var(--text); margin-bottom: 6px; }
.form-input, .form-select, .form-textarea {
    width: 100%; padding: 12px 16px;
    border: 2px solid var(--border); border-radius: var(--radius);
    font-size: 15px; transition: var(--transition); font-family: inherit;
    background: white;
}
.form-input:focus, .form-select:focus, .form-textarea:focus {
    outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px var(--primary-light);
}
.form-textarea { min-height: 120px; resize: vertical; }
.form-error { color: var(--error); font-size: 13px; margin-top: 4px; }

/* ============ CARDS ============ */
.card {
    background: white; border-radius: var(--radius-lg);
    border: 1px solid var(--border); overflow: hidden;
}
.card-body { padding: 30px; }

/* ============ PAGE HEADER ============ */
.page-header {
    background: linear-gradient(135deg, var(--primary-dark), var(--accent));
    color: white; padding: 140px 0 60px; text-align: center;
}
.page-header h1 { font-size: 42px; font-weight: 800; margin-bottom: 10px; }
.page-header p { font-size: 18px; opacity: 0.9; }

/* ============ AUTH PAGES ============ */
.auth-wrapper {
    min-height: 100vh; display: flex; align-items: center; justify-content: center;
    background: var(--bg-section); padding: 100px 20px;
}
.auth-card {
    background: white; border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl); width: 100%; max-width: 480px;
    padding: 48px 40px;
}
.auth-card h1 { text-align: center; font-size: 28px; color: var(--primary-dark); margin-bottom: 8px; }
.auth-card p { text-align: center; color: var(--text-light); margin-bottom: 32px; }

/* ============ DASHBOARD ============ */
.dashboard-layout { display: flex; min-height: 100vh; }
.dashboard-sidebar {
    width: 260px; background: var(--primary-dark); color: white;
    padding: 24px; position: fixed; top: 0; left: 0; bottom: 0;
    overflow-y: auto; z-index: 100;
}
.dashboard-main {
    margin-left: 260px; flex: 1; padding: 30px;
    background: var(--bg-section); min-height: 100vh;
}
.dash-nav-item {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 16px; border-radius: var(--radius);
    color: rgba(255,255,255,0.7); transition: var(--transition);
    margin-bottom: 4px; font-size: 14px;
}
.dash-nav-item:hover, .dash-nav-item.active {
    background: rgba(255,255,255,0.1); color: white;
}
.dash-header {
    display: flex; justify-content: space-between; align-items: center;
    margin-bottom: 30px;
}
.dash-header h1 { font-size: 28px; font-weight: 700; color: var(--text); }
.dash-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 30px; }
.dash-stat {
    background: white; border-radius: var(--radius-lg); padding: 24px;
    border: 1px solid var(--border);
}
.dash-stat-label { font-size: 13px; color: var(--text-light); text-transform: uppercase; letter-spacing: 1px; }
.dash-stat-value { font-size: 32px; font-weight: 800; color: var(--primary-dark); margin-top: 8px; }

/* ============ CALENDAR ============ */
.calendar-nav {
    display: flex; align-items: center; gap: 20px; margin-bottom: 20px;
}
.calendar-nav h2 { font-size: 24px; font-weight: 700; color: var(--text); }
.calendar-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; }
.calendar-header { background: var(--primary-dark); color: white; padding: 12px; text-align: center; font-weight: 600; }
.calendar-day {
    background: white; padding: 12px; min-height: 100px;
    border: 1px solid var(--border); position: relative;
}
.calendar-day.today { background: var(--primary-light); }
.calendar-day.other-month { opacity: 0.4; }
.calendar-day-number { font-size: 14px; font-weight: 600; margin-bottom: 4px; }
.calendar-event {
    background: var(--primary); color: white; padding: 2px 6px;
    border-radius: 4px; font-size: 11px; margin-bottom: 2px; cursor: pointer;
}
.calendar-event.blocked { background: var(--accent); }

/* ============ TABLE ============ */
.table-wrapper { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th {
    background: var(--bg-gray); padding: 12px 16px;
    text-align: left; font-size: 13px; font-weight: 600;
    color: var(--text-light); text-transform: uppercase; letter-spacing: 0.5px;
    border-bottom: 2px solid var(--border);
}
td { padding: 12px 16px; border-bottom: 1px solid var(--border); font-size: 14px; }
tr:hover td { background: var(--bg-gray); }

/* ============ ALERTS / MESSAGES ============ */
.flash-message { animation: slideIn 0.3s ease; }
@keyframes slideIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }

/* ============ NEWSLETTER FORM ============ */
.newsletter-form { display: flex; gap: 12px; max-width: 500px; margin: 0 auto; }
.newsletter-form input { flex: 1; }

/* ============ ANIMATIONS ============ */
.fade-in { animation: fadeIn 0.6s ease both; }
.fade-in-up { animation: fadeInUp 0.6s ease both; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeInUp { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }

/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) {
    .features-grid, .testimonials { grid-template-columns: repeat(2, 1fr); }
    .dash-stats { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 768px) {
    .mobile-toggle { display: flex; }
    .nav-links {
        display: none; position: absolute; top: 70px; left: 0; right: 0;
        background: white; flex-direction: column; padding: 20px;
        border-bottom: 1px solid var(--border); gap: 16px;
        box-shadow: var(--shadow-lg);
    }
    .nav-links.open { display: flex; }
    
    .hero h1 { font-size: 36px; }
    .hero p { font-size: 17px; }
    .hero-stats { flex-wrap: wrap; gap: 30px; }
    
    .features-grid, .testimonials { grid-template-columns: 1fr; }
    .steps { flex-direction: column; }
    .step::after { display: none; }
    .footer-grid { grid-template-columns: 1fr; }
    .newsletter-form { flex-direction: column; }
    
    .dashboard-sidebar { width: 100%; position: relative; height: auto; }
    .dashboard-main { margin-left: 0; }
    .dash-stats { grid-template-columns: 1fr; }
    .auth-card { padding: 30px 20px; }
    
    .section { padding: 60px 0; }
    .section-header h2 { font-size: 28px; }
    .cta-section h2 { font-size: 30px; }
}

/* ============ LOADING SPINNER ============ */
.spinner {
    display: inline-block; width: 20px; height: 20px;
    border: 2px solid var(--border); border-top-color: var(--primary);
    border-radius: 50%; animation: spin 0.6s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* ============ TOAST NOTIFICATIONS ============ */
.toast {
    position: fixed; bottom: 20px; right: 20px; z-index: 9999;
    padding: 16px 24px; border-radius: var(--radius);
    color: white; font-weight: 500; box-shadow: var(--shadow-lg);
    animation: slideInRight 0.3s ease;
    max-width: 400px;
}
.toast.success { background: var(--success); }
.toast.error { background: var(--error); }
@keyframes slideInRight { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
