/* =============================================================================
   AZALCOFFRE - Styles
   ============================================================================= */

:root {
    --primary: #2563eb;
    --primary-dark: #1d4ed8;
    --primary-light: #3b82f6;
    --secondary: #0f172a;
    --accent: #06b6d4;
    --success: #10b981;
    --warning: #f59e0b;
    --danger: #ef4444;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #94a3b8;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-800: #1e293b;
    --gray-900: #0f172a;
    --white: #ffffff;
    --gradient: linear-gradient(135deg, var(--primary) 0%, var(--accent) 100%);
    --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);
    --radius: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: var(--gray-50);
    color: var(--gray-800);
    line-height: 1.6;
}

a {
    text-decoration: none;
    color: inherit;
}

/* =============================================================================
   Navigation
   ============================================================================= */

.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--gray-200);
    padding: 0 2rem;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.navbar.scrolled {
    box-shadow: var(--shadow);
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--secondary);
}

.logo-icon {
    width: 40px;
    height: 40px;
    background: var(--gradient);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.25rem;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    color: var(--gray-600);
    font-weight: 500;
    transition: color 0.2s;
}

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

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

/* =============================================================================
   Buttons
   ============================================================================= */

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem 1.5rem;
    font-size: 0.95rem;
    font-weight: 600;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
}

.btn-primary {
    background: var(--gradient);
    color: white;
    box-shadow: 0 4px 14px 0 rgba(37, 99, 235, 0.4);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgba(37, 99, 235, 0.5);
}

.btn-secondary {
    background: var(--white);
    color: var(--gray-700);
    border: 1px solid var(--gray-300);
}

.btn-secondary:hover {
    background: var(--gray-50);
    border-color: var(--gray-400);
}

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

.btn-outline:hover {
    background: var(--primary);
    color: white;
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

.btn-icon {
    width: 42px;
    height: 42px;
    padding: 0;
    border-radius: 50%;
}

/* =============================================================================
   Hero Section
   ============================================================================= */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    padding: 100px 2rem 4rem;
    background: linear-gradient(180deg, var(--gray-50) 0%, var(--white) 100%);
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 80%;
    height: 150%;
    background: radial-gradient(circle, rgba(37, 99, 235, 0.08) 0%, transparent 70%);
    pointer-events: none;
}

.hero-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 800;
    line-height: 1.1;
    color: var(--secondary);
    margin-bottom: 1.5rem;
}

.hero-content h1 span {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-content p {
    font-size: 1.25rem;
    color: var(--gray-600);
    margin-bottom: 2rem;
    max-width: 500px;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    margin-bottom: 3rem;
}

.hero-stats {
    display: flex;
    gap: 3rem;
}

.stat {
    text-align: left;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    font-size: 0.9rem;
    color: var(--gray-500);
}

.hero-visual {
    position: relative;
}

.hero-image {
    width: 100%;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    border: 1px solid var(--gray-200);
}

.floating-card {
    position: absolute;
    background: white;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.floating-card.security {
    top: 10%;
    right: -20px;
    animation: float 3s ease-in-out infinite;
}

.floating-card.compliance {
    bottom: 20%;
    left: -30px;
    animation: float 3s ease-in-out infinite 1s;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.card-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.card-icon.green {
    background: #dcfce7;
    color: var(--success);
}

.card-icon.blue {
    background: #dbeafe;
    color: var(--primary);
}

/* =============================================================================
   Features Section
   ============================================================================= */

.section {
    padding: 6rem 2rem;
}

.section-dark {
    background: var(--secondary);
    color: white;
}

.section-gray {
    background: var(--gray-100);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-header {
    text-align: center;
    margin-bottom: 4rem;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.section-header p {
    font-size: 1.1rem;
    color: var(--gray-500);
    max-width: 600px;
    margin: 0 auto;
}

.section-dark .section-header p {
    color: var(--gray-400);
}

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

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    transition: all 0.3s;
    border: 1px solid var(--gray-200);
}

.feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.feature-icon {
    width: 60px;
    height: 60px;
    border-radius: var(--radius-lg);
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: white;
    margin-bottom: 1.5rem;
}

.feature-card h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
    color: var(--secondary);
}

.feature-card p {
    color: var(--gray-600);
    font-size: 0.95rem;
}

/* =============================================================================
   Pricing Section
   ============================================================================= */

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    align-items: start;
}

.pricing-card {
    background: white;
    border-radius: var(--radius-xl);
    padding: 2.5rem;
    box-shadow: var(--shadow);
    border: 1px solid var(--gray-200);
    position: relative;
    transition: all 0.3s;
}

.pricing-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-xl);
}

.pricing-card.featured {
    border: 2px solid var(--primary);
    transform: scale(1.05);
}

.pricing-card.featured:hover {
    transform: scale(1.05) translateY(-5px);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--gradient);
    color: white;
    padding: 0.25rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.pricing-header {
    text-align: center;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--gray-200);
    margin-bottom: 1.5rem;
}

.pricing-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

.pricing-header .price {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary);
}

.pricing-header .price span {
    font-size: 1rem;
    color: var(--gray-500);
    font-weight: 400;
}

.pricing-features {
    list-style: none;
    margin-bottom: 2rem;
}

.pricing-features li {
    padding: 0.5rem 0;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--gray-600);
}

.pricing-features li::before {
    content: '✓';
    color: var(--success);
    font-weight: 700;
}

.pricing-card .btn {
    width: 100%;
}

/* =============================================================================
   Auth Pages
   ============================================================================= */

.auth-page {
    min-height: 100vh;
    display: flex;
}

.auth-left {
    flex: 1;
    background: var(--gradient);
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem;
    color: white;
    position: relative;
    overflow: hidden;
}

.auth-left::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.1) 0%, transparent 70%);
}

.auth-left h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    position: relative;
}

.auth-left p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 400px;
    position: relative;
}

.auth-features {
    margin-top: 3rem;
    position: relative;
}

.auth-feature {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.auth-feature-icon {
    width: 48px;
    height: 48px;
    background: rgba(255,255,255,0.2);
    border-radius: var(--radius);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.auth-right {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 4rem;
    background: white;
}

.auth-form-container {
    max-width: 400px;
    margin: 0 auto;
    width: 100%;
}

.auth-logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 2rem;
}

.auth-form-container h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

.auth-form-container > p {
    color: var(--gray-500);
    margin-bottom: 2rem;
}

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

.form-group label {
    display: block;
    font-weight: 500;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 0.875rem 1rem;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    font-size: 1rem;
    transition: all 0.2s;
    background: white;
}

.form-group input:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

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

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.checkbox-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.checkbox-group input {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

.forgot-link {
    color: var(--primary);
    font-weight: 500;
}

.auth-divider {
    display: flex;
    align-items: center;
    margin: 2rem 0;
    color: var(--gray-400);
}

.auth-divider::before,
.auth-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--gray-300);
}

.auth-divider span {
    padding: 0 1rem;
    font-size: 0.9rem;
}

.auth-footer {
    text-align: center;
    margin-top: 2rem;
    color: var(--gray-600);
}

.auth-footer a {
    color: var(--primary);
    font-weight: 600;
}

/* =============================================================================
   Demo Section
   ============================================================================= */

.demo-container {
    background: white;
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    overflow: hidden;
    border: 1px solid var(--gray-200);
}

.demo-header {
    background: var(--secondary);
    color: white;
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.demo-dots {
    display: flex;
    gap: 0.5rem;
}

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

.demo-dot.red { background: #ef4444; }
.demo-dot.yellow { background: #f59e0b; }
.demo-dot.green { background: #10b981; }

.demo-tabs {
    display: flex;
    gap: 0.5rem;
}

.demo-tab {
    padding: 0.5rem 1rem;
    background: rgba(255,255,255,0.1);
    border-radius: var(--radius);
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}

.demo-tab.active,
.demo-tab:hover {
    background: rgba(255,255,255,0.2);
}

.demo-content {
    padding: 2rem;
    min-height: 400px;
}

.demo-sidebar {
    display: flex;
    gap: 2rem;
}

.demo-menu {
    width: 200px;
    border-right: 1px solid var(--gray-200);
    padding-right: 2rem;
}

.demo-menu-item {
    padding: 0.75rem 1rem;
    border-radius: var(--radius);
    margin-bottom: 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    color: var(--gray-600);
    transition: all 0.2s;
}

.demo-menu-item:hover,
.demo-menu-item.active {
    background: var(--gray-100);
    color: var(--primary);
}

.demo-main {
    flex: 1;
}

.demo-card {
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius);
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.demo-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.demo-card h4 {
    font-weight: 600;
    color: var(--secondary);
}

.badge {
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.badge-success {
    background: #dcfce7;
    color: var(--success);
}

.badge-warning {
    background: #fef3c7;
    color: var(--warning);
}

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

/* =============================================================================
   Footer
   ============================================================================= */

.footer {
    background: var(--secondary);
    color: var(--gray-400);
    padding: 4rem 2rem 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 3rem;
    max-width: 1200px;
    margin: 0 auto 3rem;
}

.footer-brand {
    max-width: 300px;
}

.footer-brand .logo {
    color: white;
    margin-bottom: 1rem;
}

.footer-brand p {
    font-size: 0.95rem;
    line-height: 1.7;
}

.footer-links h4 {
    color: white;
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
}

.footer-links ul {
    list-style: none;
}

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

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid var(--gray-700);
    padding-top: 2rem;
    text-align: center;
    font-size: 0.9rem;
}

/* =============================================================================
   Alerts & Messages
   ============================================================================= */

.alert {
    padding: 1rem 1.5rem;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.alert-success {
    background: #dcfce7;
    color: #166534;
    border: 1px solid #86efac;
}

.alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fca5a5;
}

.alert-info {
    background: #dbeafe;
    color: #1e40af;
    border: 1px solid #93c5fd;
}

/* =============================================================================
   Mobile Menu
   ============================================================================= */

.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 5px;
    padding: 0.5rem;
    background: none;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 24px;
    height: 2px;
    background: var(--gray-700);
    transition: all 0.3s;
}

.mobile-menu {
    display: none;
    position: fixed;
    top: 70px;
    left: 0;
    right: 0;
    bottom: 0;
    background: white;
    padding: 2rem;
    z-index: 999;
    flex-direction: column;
    gap: 1rem;
}

.mobile-menu.active {
    display: flex;
}

.mobile-menu a {
    padding: 1rem;
    font-size: 1.1rem;
    font-weight: 500;
    color: var(--gray-700);
    border-bottom: 1px solid var(--gray-200);
}

.mobile-menu a:hover {
    color: var(--primary);
}

.mobile-menu .btn {
    margin-top: 1rem;
}

/* =============================================================================
   Responsive
   ============================================================================= */

@media (max-width: 1024px) {
    .hero-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .hero-content p {
        margin: 0 auto 2rem;
    }

    .hero-buttons {
        justify-content: center;
        flex-wrap: wrap;
    }

    .hero-stats {
        justify-content: center;
        flex-wrap: wrap;
        gap: 2rem;
    }

    .hero-visual {
        display: none;
    }

    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .pricing-grid {
        grid-template-columns: 1fr;
        max-width: 450px;
        margin: 0 auto;
    }

    .pricing-card.featured {
        transform: none;
    }

    .auth-left {
        display: none;
    }

    .auth-right {
        padding: 2rem;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .demo-sidebar {
        flex-direction: column;
    }

    .demo-menu {
        width: 100%;
        border-right: none;
        border-bottom: 1px solid var(--gray-200);
        padding-right: 0;
        padding-bottom: 1rem;
        display: flex;
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .demo-menu-item {
        margin-bottom: 0;
    }
}

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

    .nav-links,
    .nav-buttons {
        display: none;
    }

    .mobile-menu-toggle {
        display: flex;
    }

    .hero {
        padding: 90px 1rem 3rem;
        min-height: auto;
    }

    .hero-content h1 {
        font-size: 2rem;
        line-height: 1.2;
    }

    .hero-content p {
        font-size: 1rem;
    }

    .hero-buttons {
        flex-direction: column;
        gap: 0.75rem;
    }

    .hero-buttons .btn {
        width: 100%;
    }

    .hero-stats {
        flex-direction: column;
        gap: 1.5rem;
    }

    .stat {
        text-align: center;
    }

    .section {
        padding: 3rem 1rem;
    }

    .section-header h2 {
        font-size: 1.75rem;
    }

    .section-header p {
        font-size: 1rem;
    }

    .features-grid {
        grid-template-columns: 1fr;
        max-width: 100%;
    }

    .feature-card {
        padding: 1.5rem;
    }

    .pricing-card {
        padding: 1.5rem;
    }

    .pricing-header .price {
        font-size: 2.5rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .footer-brand {
        max-width: 100%;
    }

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

    .auth-form-container h2 {
        font-size: 1.5rem;
    }

    .demo-content {
        padding: 1rem;
    }

    .demo-header {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .demo-tabs {
        order: 3;
        width: 100%;
        justify-content: center;
        margin-top: 0.5rem;
    }

    .demo-card {
        padding: 1rem;
    }

    .demo-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}

@media (max-width: 480px) {
    .navbar {
        height: 60px;
    }

    .logo {
        font-size: 1.25rem;
    }

    .logo-icon {
        width: 36px;
        height: 36px;
        font-size: 1rem;
    }

    .hero-content h1 {
        font-size: 1.75rem;
    }

    .btn-lg {
        padding: 0.875rem 1.5rem;
        font-size: 1rem;
    }

    .stat-value {
        font-size: 1.5rem;
    }

    .section-header h2 {
        font-size: 1.5rem;
    }

    .feature-icon {
        width: 50px;
        height: 50px;
        font-size: 1.25rem;
    }

    .pricing-badge {
        font-size: 0.7rem;
        padding: 0.2rem 0.75rem;
    }

    .auth-right {
        padding: 1.5rem;
    }

    .form-group input,
    .form-group select {
        padding: 0.75rem;
    }
}

/* Touch-friendly improvements */
@media (hover: none) {
    .btn:hover {
        transform: none;
    }

    .feature-card:hover {
        transform: none;
    }

    .pricing-card:hover {
        transform: none;
    }

    .btn:active {
        transform: scale(0.98);
    }
}

/* =============================================================================
   Animations
   ============================================================================= */

.fade-in {
    animation: fadeIn 0.5s ease-out;
}

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

.slide-up {
    animation: slideUp 0.6s ease-out;
}

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

/* Loading spinner */
.spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255,255,255,0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}
