:root {
    --primary: #f59e0b;
    --primary-dim: rgba(245, 158, 11, 0.15);
    --bg: #0a0a0a;
    --bg-card: rgba(255, 255, 255, 0.04);
    --bg-card-hover: rgba(255, 255, 255, 0.07);
    --bg-card-alt: rgba(255, 255, 255, 0.08);
    --text: #e5e5e5;
    --text-dim: #888;
    --text-bright: #fff;
    --border: rgba(255, 255, 255, 0.08);
    --radius: 12px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --danger: #ef4444;
}

/* === LIGHT THEME === */
[data-theme="light"] {
    --bg: #f5f5f7; --bg-card: #ffffff; --bg-card-hover: #f0f0f2; --bg-card-alt: #f3f4f6;
    --text: #374151; --text-dim: #6b7280; --text-bright: #111827;
    --border: rgba(0, 0, 0, 0.1); --primary-dim: rgba(245, 158, 11, 0.1);
}
.theme-toggle-float {
    position: fixed; bottom: 1.25rem; right: 1.25rem; width: 40px; height: 40px;
    border-radius: 50%; background: var(--bg-card); border: 1px solid var(--border);
    color: var(--text-dim); cursor: pointer; display: flex; align-items: center;
    justify-content: center; z-index: 1000; transition: all 0.2s;
    backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}
.theme-toggle-float:hover { color: var(--text-bright); transform: scale(1.1); }
@media print { .theme-toggle-float { display: none !important; } }

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* === NAV === */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    background: rgba(10, 10, 10, 0.85);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--border);
}
.nav-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.nav-logo {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--text-bright);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.nav-logo-img {
    height: 32px;
    width: auto;
}
.nav-links { display: flex; gap: 0.5rem; align-items: center; }
.nav-link {
    color: var(--text-dim);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    transition: color 0.2s, background 0.2s;
}
.nav-link:hover {
    color: var(--text-bright);
    background: var(--bg-card);
}
.nav-toggle { display: none; background: none; border: none; cursor: pointer; padding: 0.5rem; }
.nav-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    margin: 5px 0;
    border-radius: 2px;
    transition: transform 0.3s, opacity 0.3s;
}

/* === BUTTONS === */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1.75rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
    transition: transform 0.2s, box-shadow 0.2s, opacity 0.2s;
    cursor: pointer;
    border: none;
    font-family: var(--font);
}
.btn:hover { transform: translateY(-2px); }
.btn-primary {
    background: var(--primary);
    color: #000;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.3);
}
.btn-primary:hover { box-shadow: 0 6px 25px rgba(245, 158, 11, 0.4); }
.btn-outline {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--text-dim); background: var(--bg-card); }
.btn-sm { padding: 0.5rem 1.25rem; font-size: 0.825rem; }
.btn-lg { padding: 1rem 2rem; font-size: 1rem; }
.btn-block { width: 100%; justify-content: center; }

/* === HERO === */
.hero {
    padding: 8rem 1.5rem 3rem;
    text-align: center;
}
.hero-content { max-width: 680px; margin: 0 auto; }
.hero-title {
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 800;
    color: var(--text-bright);
    line-height: 1.15;
    margin-bottom: 0.75rem;
}
.hero-subtitle {
    font-size: 1.05rem;
    color: var(--text-dim);
    max-width: 520px;
    margin: 0 auto;
    line-height: 1.7;
}

/* === STATS BAR === */
.stats-bar {
    padding: 1.5rem;
    border-bottom: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.015);
}
.stats-grid {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}
.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.375rem;
}
.stat-stars {
    display: flex;
    gap: 3px;
}
.stat-number {
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--text-bright);
    line-height: 1;
}
.stat-number .stat-label { font-size: 1rem; font-weight: 500; color: var(--text-dim); }
.stat-big { font-size: 2.25rem; }
.stat-label {
    font-size: 0.8rem;
    color: var(--text-dim);
}
.stat-divider {
    width: 1px;
    height: 40px;
    background: var(--border);
}

/* === STARS === */
.star {
    width: 20px;
    height: 20px;
}
.star-filled { fill: var(--primary); }
.star-half { fill: var(--primary); }
.star-empty { fill: var(--text-dim); opacity: 0.3; }
.star-xs { width: 14px; height: 14px; }

/* === FILTERS === */
.filters-bar {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border);
}
.filters {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}
.filter-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    padding: 0.375rem 0.875rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-dim);
    text-decoration: none;
    border: 1px solid var(--border);
    transition: all 0.2s;
    white-space: nowrap;
}
.filter-chip:hover {
    color: var(--text-bright);
    border-color: var(--text-dim);
}
.filter-chip.active {
    background: var(--primary);
    color: #000;
    border-color: var(--primary);
    font-weight: 600;
}
.filter-chip.active .star-filled { fill: #000; }
.filter-star { gap: 0.2rem; }
.filter-separator {
    width: 1px;
    height: 20px;
    background: var(--border);
    margin: 0 0.25rem;
}

/* === SECTIONS === */
.section { padding: 3rem 1.5rem; }
.container { max-width: 900px; margin: 0 auto; }
.container-wide { max-width: 1200px; margin: 0 auto; }
.container-sm { max-width: 640px; margin: 0 auto; }

/* === TESTIMONIALS GRID === */
.masonry {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}
.testimonial-card {
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: var(--radius);
    padding: 1.75rem;
    transition: transform 0.3s, border-color 0.3s, box-shadow 0.3s;
    position: relative;
    color: #374151;
}
.testimonial-card:nth-child(odd) {
    background: #f8f9fa;
}
.testimonial-card:nth-child(even) {
    background: #ffffff;
}
.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.1);
    border-color: #d1d5db;
}

/* Featured card */
.testimonial-card.featured {
    border-color: var(--primary);
    box-shadow: 0 0 20px rgba(245, 158, 11, 0.1), inset 0 0 0 1px rgba(245, 158, 11, 0.1);
}
.featured-badge {
    position: absolute;
    top: -1px;
    right: 1rem;
    background: var(--primary);
    color: #000;
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 0.25rem 0.625rem;
    border-radius: 0 0 6px 6px;
}

/* Card header */
.card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.875rem;
}
.avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--primary);
    color: #000;
    font-weight: 700;
    font-size: 1.3rem;
    box-shadow: 0 0 0 3px var(--primary-dim);
}
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar-initials { line-height: 1; }
.card-author { min-width: 0; }
.author-name {
    font-weight: 600;
    font-size: 0.95rem;
    color: #111827;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.author-info {
    font-size: 0.8rem;
    color: #6b7280;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Card stars */
.card-stars {
    display: flex;
    gap: 2px;
    margin-bottom: 0.75rem;
}
.card-stars .star { width: 16px; height: 16px; }

/* Card content */
.card-content {
    font-size: 0.925rem;
    color: #4b5563;
    line-height: 1.7;
    position: relative;
    padding-left: 0;
}
.quote-icon {
    width: 20px;
    height: 20px;
    color: var(--primary);
    opacity: 0.3;
    margin-bottom: 0.375rem;
    display: block;
}

/* Card category */
.card-category {
    display: inline-block;
    margin-top: 0.875rem;
    font-size: 0.7rem;
    font-weight: 500;
    padding: 0.2rem 0.5rem;
    border-radius: 50px;
    background: var(--primary-dim);
    color: var(--primary);
}

/* === EMPTY STATE === */
.empty-state {
    text-align: center;
    padding: 4rem 1rem;
}
.empty-icon {
    width: 48px;
    height: 48px;
    color: var(--text-dim);
    margin-bottom: 1rem;
}
.empty-state h3 {
    font-size: 1.25rem;
    color: var(--text-bright);
    margin-bottom: 0.5rem;
}
.empty-state p {
    color: var(--text-dim);
    margin-bottom: 1.5rem;
}

/* === FORM === */
.section-form {
    padding-top: 7rem;
    min-height: 100vh;
}
.form-header {
    text-align: center;
    margin-bottom: 2.5rem;
}
.form-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-bright);
    margin-bottom: 0.5rem;
}
.form-subtitle {
    color: var(--text-dim);
    font-size: 1.05rem;
}
.review-form {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 2rem;
}
.form-group {
    margin-bottom: 1.5rem;
}
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}
.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-bright);
    margin-bottom: 0.5rem;
}
.form-input {
    width: 100%;
    padding: 0.75rem 1rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: 10px;
    color: var(--text-bright);
    font-size: 0.9rem;
    font-family: var(--font);
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}
.form-input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px var(--primary-dim);
}
.form-input::placeholder { color: var(--text-dim); opacity: 0.6; }
.form-textarea { resize: vertical; min-height: 120px; }
.form-select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2'%3E%3Cpolyline points='6 9 12 15 18 9'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}
.form-select option { background: #1a1a1a; color: var(--text); }
.form-hint {
    font-size: 0.75rem;
    color: var(--text-dim);
    margin-top: 0.375rem;
}
.form-error {
    font-size: 0.8rem;
    color: var(--danger);
    margin-top: 0.375rem;
    font-weight: 500;
}
.form-note {
    text-align: center;
    font-size: 0.8rem;
    color: var(--text-dim);
    margin-top: 1rem;
}

/* Star rating input */
.star-rating {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}
.star-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 2px;
    transition: transform 0.15s;
}
.star-btn:hover { transform: scale(1.2); }
.star-btn svg {
    width: 32px;
    height: 32px;
    fill: var(--text-dim);
    opacity: 0.3;
    transition: fill 0.15s, opacity 0.15s;
}
.star-btn.active svg,
.star-btn.hover svg {
    fill: var(--primary);
    opacity: 1;
}
.rating-text {
    margin-left: 0.75rem;
    font-size: 0.85rem;
    color: var(--text-dim);
    font-weight: 500;
}

/* File upload */
.file-upload {
    position: relative;
    border: 2px dashed var(--border);
    border-radius: 10px;
    padding: 1.5rem;
    text-align: center;
    transition: border-color 0.2s;
    cursor: pointer;
}
.file-upload:hover { border-color: var(--primary); }
.file-upload.dragover { border-color: var(--primary); background: var(--primary-dim); }
.file-input {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}
.file-upload-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}
.file-icon {
    width: 24px;
    height: 24px;
    color: var(--text-dim);
}
.file-text {
    font-size: 0.85rem;
    color: var(--text-dim);
}
.file-name {
    font-size: 0.8rem;
    color: var(--primary);
    font-weight: 500;
}

/* === THANKS === */
.section-thanks {
    padding-top: 7rem;
    min-height: 100vh;
    display: flex;
    align-items: center;
}
.thanks-content {
    text-align: center;
    max-width: 480px;
    margin: 0 auto;
}
.thanks-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(34, 197, 94, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}
.thanks-icon svg {
    width: 40px;
    height: 40px;
    color: #22c55e;
}
.thanks-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-bright);
    margin-bottom: 0.75rem;
}
.thanks-text {
    color: var(--text-dim);
    font-size: 1.05rem;
    line-height: 1.7;
    margin-bottom: 2rem;
}
.thanks-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* === FOOTER === */
.footer {
    padding: 2rem 1.5rem;
    border-top: 1px solid var(--border);
    text-align: center;
}
.badge-link {
    font-size: 0.75rem;
    color: var(--text-dim);
    text-decoration: none;
    opacity: 0.6;
    transition: opacity 0.2s;
}
.badge-link:hover { opacity: 1; }

/* === ANIMATIONS === */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered animation for cards */
.masonry .testimonial-card:nth-child(1) { transition-delay: 0s; }
.masonry .testimonial-card:nth-child(2) { transition-delay: 0.05s; }
.masonry .testimonial-card:nth-child(3) { transition-delay: 0.1s; }
.masonry .testimonial-card:nth-child(4) { transition-delay: 0.15s; }
.masonry .testimonial-card:nth-child(5) { transition-delay: 0.2s; }
.masonry .testimonial-card:nth-child(6) { transition-delay: 0.25s; }
.masonry .testimonial-card:nth-child(7) { transition-delay: 0.3s; }
.masonry .testimonial-card:nth-child(8) { transition-delay: 0.35s; }
.masonry .testimonial-card:nth-child(9) { transition-delay: 0.4s; }

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

@media (max-width: 768px) {
    .nav-toggle { display: block; }
    .nav-links {
        display: none;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: rgba(10, 10, 10, 0.95);
        backdrop-filter: blur(12px);
        -webkit-backdrop-filter: blur(12px);
        flex-direction: column;
        padding: 1rem;
        border-bottom: 1px solid var(--border);
        align-items: stretch;
    }
    .nav-links.open { display: flex; }
    .nav-links .btn { text-align: center; justify-content: center; }
    .hero { padding: 6rem 1.25rem 2rem; }
    .hero-title { font-size: clamp(1.75rem, 5vw, 2.5rem); }
    .section { padding: 2rem 1.25rem; }
    .masonry { grid-template-columns: 1fr; }
    .stats-grid { gap: 1.25rem; }
    .stat-divider { display: none; }
    .form-row { grid-template-columns: 1fr; }
    .review-form { padding: 1.5rem; }
    .thanks-actions { flex-direction: column; align-items: center; }
    .filter-separator { display: none; }
}

/* === PRINT === */
@media print {
    * { background: #fff !important; color: #111 !important; box-shadow: none !important; }
    .nav, .footer, .filters-bar, .btn { display: none !important; }
    .hero { padding: 1rem 0; }
    .section { padding: 1rem 0; }
    .masonry { grid-template-columns: repeat(2, 1fr); }
    .testimonial-card {
        border: 1px solid #ddd !important;
        background: #fafafa !important;
        break-inside: avoid;
    }
    .star-filled { fill: #333 !important; }
    .fade-in { opacity: 1 !important; transform: none !important; }
}
