/* Reset and Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary: #0066FF;
    --primary-dark: #0052CC;
    --text-primary: #1a1a1a;
    --text-secondary: #666;
    --text-light: #999;
    --bg-light: #F9FAFB;
    --border: #E5E7EB;
    --white: #ffffff;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 18px;
    line-height: 1.7;
    color: var(--text-primary);
    background: linear-gradient(180deg, #fafbff 0%, #ffffff 50%, #fafbff 100%);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    position: relative;
    overflow-x: hidden;
}

/* Particle Canvas Background */
#particle-canvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    pointer-events: none;
}

/* Navigation Bar */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(229, 231, 235, 0.8);
    z-index: 1000;
    padding: 16px 0;
}

.navbar-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-logo {
    font-size: 24px;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary) 0%, #0052CC 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.navbar-btn {
    height: 44px;
    padding: 0 32px;
    background: var(--primary);
    color: var(--white);
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 102, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

.navbar-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 102, 255, 0.3);
}

/* Layout */
.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 32px 24px;
}

.container-wide {
    max-width: 1400px;
    margin: 0 auto;
    padding: 32px 40px;
}

/* Hero Section */
.hero {
    min-height: 85vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 120px 24px 40px;
    background: transparent;
}

.hero h1 {
    font-size: 56px;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 24px;
    background: linear-gradient(135deg, var(--primary) 0%, #0052CC 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero .subtitle {
    font-size: 24px;
    color: var(--text-secondary);
    margin-bottom: 48px;
    max-width: 900px;
    line-height: 1.6;
}

.hero-image {
    width: 100%;
    max-width: 700px;
    margin: 32px auto 48px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 102, 255, 0.15);
    overflow: hidden;
    background: var(--white);
    padding: 20px;
}

.hero-image img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}

/* Features Section */
.features {
    padding: 40px 24px 80px;
    background: transparent;
}

.section-title {
    text-align: center;
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 64px;
    color: var(--text-primary);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 48px;
    max-width: 1400px;
    margin: 0 auto;
}

.feature-card {
    text-align: center;
    padding: 40px 24px;
    background: var(--bg-light);
    border-radius: 12px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
}

.feature-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 24px;
    background: linear-gradient(135deg, var(--primary) 0%, #0052CC 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    box-shadow: 0 4px 12px rgba(0, 102, 255, 0.2);
}

.feature-icon img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    filter: brightness(0) invert(1);
}

.feature-card h3 {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-primary);
}

.feature-card p {
    color: var(--text-secondary);
    font-size: 16px;
    line-height: 1.6;
    margin: 0;
}

/* Typography */
h1 {
    font-size: 32px;
    font-weight: 600;
    margin-bottom: 16px;
}

h2 {
    font-size: 22px;
    font-weight: 600;
    margin-bottom: 16px;
    margin-top: 40px;
    color: var(--text-primary);
}

h2:first-of-type {
    margin-top: 32px;
}

p {
    font-size: 18px;
    margin-bottom: 24px;
    color: var(--text-primary);
}

ul, ol {
    margin-bottom: 24px;
    padding-left: 32px;
}

ul li, ol li {
    margin-bottom: 12px;
    line-height: 1.7;
    color: var(--text-primary);
}

.container ul li strong,
.container ol li strong {
    color: var(--primary);
}

.text-secondary {
    color: var(--text-secondary);
    font-size: 14px;
}

.text-light {
    color: var(--text-light);
}

/* Buttons */
button, .btn {
    height: 56px;
    padding: 0 40px;
    border: none;
    background: var(--primary);
    color: var(--white);
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 8px;
    font-family: inherit;
    display: inline-block;
    text-decoration: none;
    line-height: 56px;
    text-align: center;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 102, 255, 0.2);
}

button:hover, .btn:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 102, 255, 0.3);
}

button:disabled, .btn:disabled {
    background: var(--border);
    color: var(--text-light);
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

button.btn-secondary {
    background: var(--white);
    color: var(--primary);
    border: 2px solid var(--primary);
    box-shadow: none;
}

button.btn-secondary:hover {
    background: var(--bg-light);
}

button.btn-danger {
    background: #DC3545;
}

button.btn-danger:hover {
    background: #c82333;
}

button.btn-full {
    width: 100%;
}

.cta-buttons {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* Inputs */
input, textarea {
    width: 100%;
    height: 48px;
    padding: 0 16px;
    border: 1px solid #E0E0E0;
    border-radius: 4px;
    font-size: 18px;
    font-family: inherit;
    color: #000;
    background: #fff;
}

input:focus, textarea:focus {
    outline: none;
    border-color: #000;
}

textarea {
    height: auto;
    min-height: 96px;
    padding: 12px 16px;
    resize: vertical;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}

.form-group {
    margin-bottom: 24px;
}

/* OTP Input */
.otp-container {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin: 24px 0;
}

.otp-input {
    width: 48px;
    height: 56px;
    text-align: center;
    font-size: 24px;
    font-family: monospace;
    padding: 0;
}

/* File Upload */
.upload-zone {
    border: 2px dashed #E0E0E0;
    border-radius: 4px;
    padding: 32px;
    text-align: center;
    cursor: pointer;
    transition: background 0.2s;
}

.upload-zone:hover {
    background: #F5F5F5;
}

.upload-zone.drag-over {
    background: #F5F5F5;
    border-color: #000;
}

.file-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    background: #F5F5F5;
    border-radius: 4px;
    margin-top: 16px;
}

.file-info .file-name {
    font-weight: 600;
}

.file-info button {
    height: 32px;
    padding: 0 16px;
    font-size: 14px;
    background: transparent;
    color: #DC3545;
    border: 1px solid #DC3545;
}

/* Chat Interface */
.chat-container {
    display: flex;
    flex-direction: column;
    height: 100vh;
}

.chat-header {
    height: 48px;
    border-bottom: 1px solid #E0E0E0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    background: #fff;
    position: sticky;
    top: 0;
    z-index: 10;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 24px 16px;
}

.message {
    margin-bottom: 24px;
}

.message.user {
    text-align: right;
}

.message.user .message-content {
    font-weight: 600;
}

.message-label {
    font-size: 14px;
    color: #666;
    margin-bottom: 4px;
}

.message-content {
    font-size: 18px;
    line-height: 1.6;
    white-space: pre-wrap;
}

.chat-input-container {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    border-top: 1px solid #E0E0E0;
    padding: 16px;
}

.chat-input-btn {
    width: 100%;
    height: 60px;
    background: #F5F5F5;
    color: #000;
    border: 2px solid transparent;
}

.chat-input-btn:hover {
    background: #E0E0E0;
}

.chat-input-btn.recording {
    border-color: #DC3545;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { border-color: #DC3545; }
    50% { border-color: #ff6b7a; }
}

/* List/Table */
.list-item {
    border-bottom: 1px solid #E0E0E0;
    padding: 16px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.list-item:hover {
    background: #F5F5F5;
}

.list-item-title {
    font-weight: 600;
}

.list-item-meta {
    font-size: 14px;
    color: #666;
    margin-top: 4px;
}

/* Footer */
.footer {
    text-align: center;
    padding: 32px 16px;
    border-top: 1px solid #E0E0E0;
    margin-top: 48px;
}

.footer a {
    color: #666;
    text-decoration: none;
    font-size: 14px;
    margin: 0 16px;
}

.footer a:hover {
    color: #000;
}

/* Modal/Popup */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 16px;
}

.modal-card {
    background: var(--white);
    border-radius: 12px;
    padding: 40px;
    max-width: 450px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: modalSlideIn 0.3s ease-out;
}

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

.modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    background: transparent;
    border: none;
    font-size: 24px;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px 8px;
    height: auto;
    box-shadow: none;
    line-height: 1;
}

.modal-close:hover {
    color: var(--text-primary);
    background: transparent;
    transform: none;
}

.modal-card h1 {
    font-size: 28px;
    margin-bottom: 24px;
    text-align: center;
}

/* Utilities */
.text-center {
    text-align: center;
}

.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }

.hidden {
    display: none !important;
}

/* Loading State */
.loading {
    color: #666;
    font-style: italic;
}

/* Error Messages */
.error {
    color: #DC3545;
    font-size: 14px;
    margin-top: 8px;
}

/* Mobile Optimizations */
@media (max-width: 768px) {
    body {
        font-size: 16px;
    }

    h1 {
        font-size: 28px;
    }

    .container, .container-wide {
        padding: 24px 16px;
    }

    button, .btn, input, textarea {
        font-size: 16px;
    }

    .hero {
        min-height: 70vh;
        padding: 60px 16px;
    }

    .hero h1 {
        font-size: 36px;
    }

    .hero .subtitle {
        font-size: 18px;
        margin-bottom: 32px;
    }

    .hero-image {
        max-width: 100%;
        margin: 24px auto 32px;
        padding: 16px;
        border-radius: 16px;
    }

    .section-title {
        font-size: 32px;
        margin-bottom: 40px;
    }

    .features {
        padding: 60px 16px;
    }

    .features-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .feature-card {
        padding: 32px 20px;
    }

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

    .cta-buttons button {
        width: 100%;
    }

    .navbar-content {
        padding: 0 16px;
    }

    .navbar-logo {
        font-size: 20px;
    }

    .navbar-btn {
        height: 40px;
        padding: 0 24px;
        font-size: 15px;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .hero h1 {
        font-size: 48px;
    }

    .hero .subtitle {
        font-size: 20px;
    }

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