
/* ========== VARIABLES ========== */
:root {
    --royal-blue: #1a3c6d;
    --royal-blue-light: #2a5298;
    --royal-blue-dark: #0f2440;
    --teal: #0d9488;
    --teal-light: #14b8a6;
    --teal-dark: #0f766e;
    --white: #ffffff;
    --gray-50: #f8fafc;
    --gray-100: #f1f5f9;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-600: #475569;
    --gray-700: #334155;
    --gray-900: #0f172a;
    --font-sans: 'Inter', system-ui, -apple-system, sans-serif;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
    --transition: 0.2s ease;
}

[data-theme="dark"] {
    --royal-blue: #2a5298;
    --teal: #14b8a6;
    --white: #0f172a;
    --gray-50: #1e293b;
    --gray-100: #334155;
    --gray-200: #475569;
    --gray-300: #64748b;
    --gray-600: #cbd5e1;
    --gray-700: #e2e8f0;
    --gray-900: #f8fafc;
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.3);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.4);
    --shadow-lg: 0 10px 15px rgba(0,0,0,0.5);
}

/* ========== RESET & BASE ========== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-sans);
    background: var(--white);
    color: var(--gray-900);
    line-height: 1.6;
    transition: background 0.3s, color 0.3s;
}
a { color: var(--royal-blue); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--teal); }
img { max-width: 100%; display: block; }
.skip-link { position: absolute; top: -100px; left: 0; background: var(--royal-blue); color: white; padding: 8px 16px; z-index: 1000; transition: top 0.3s; }
.skip-link:focus { top: 0; }
h1, h2, h3, h4, h5, h6 { line-height: 1.2; }

/* ========== UTILITIES ========== */
.text--royal { color: var(--royal-blue); }
.text--teal { color: var(--teal); }
.badge {
    display: inline-block; padding: 4px 12px; border-radius: 50px; font-size: 0.75rem; font-weight: 600;
}
.badge--teal { background: rgba(13,148,136,0.1); color: var(--teal); }
.tag {
    font-size: 0.875rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em;
}
.tag--royal { color: var(--royal-blue); }
.tag--teal { color: var(--teal); }
.w-full { width: 100%; }

/* ========== BUTTONS ========== */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 10px 24px; border-radius: var(--radius-sm); font-weight: 600;
    font-size: 0.9375rem; cursor: pointer; transition: all var(--transition);
    border: 2px solid transparent; background: none;
}
.btn--primary { background: var(--royal-blue); color: white; border-color: var(--royal-blue); }
.btn--primary:hover { background: var(--royal-blue-light); border-color: var(--royal-blue-light); }
.btn--outline { background: transparent; color: var(--royal-blue); border-color: var(--royal-blue); }
.btn--outline:hover { background: var(--royal-blue); color: white; }
.btn--white { background: white; color: var(--royal-blue); border-color: white; }
.btn--white:hover { background: var(--gray-100); }
.btn--outline-white { background: transparent; color: white; border-color: white; }
.btn--outline-white:hover { background: white; color: var(--royal-blue); }
.btn--lg { padding: 14px 32px; font-size: 1rem; }
.btn--sm { padding: 8px 16px; font-size: 0.875rem; }

/* ========== NAVBAR ========== */
.navbar {
    position: sticky; top: 0; z-index: 100; padding: 12px 0;
    background: var(--white); border-bottom: 1px solid var(--gray-200);
    transition: background 0.3s, border-color 0.3s;
}
.navbar--transparent { background: transparent; border-bottom-color: transparent; }
.navbar__container {
    max-width: 1280px; margin: 0 auto; padding: 0 24px;
    display: flex; align-items: center; justify-content: space-between;
}
.navbar__brand { font-size: 1.75rem; font-weight: 800; color: var(--royal-blue); }
.navbar__brand-name { letter-spacing: -0.5px; }
.navbar__toggle { display: none; background: none; border: none; cursor: pointer; }
.navbar__toggle-bar { display: block; width: 24px; height: 2px; background: var(--gray-900); margin: 5px 0; }
.navbar__menu { display: flex; align-items: center; gap: 24px; }
.navbar__links { list-style: none; display: flex; gap: 20px; }
.navbar__link { color: var(--gray-700); font-weight: 500; }
.navbar__link:hover { color: var(--teal); }
.navbar__dropdown { position: relative; }
.navbar__dropdown-toggle { background: none; border: none; cursor: pointer; font: inherit; }
.navbar__dropdown-menu {
    display: none; position: absolute; top: 100%; left: 0; background: var(--white);
    border: 1px solid var(--gray-200); border-radius: var(--radius-sm); min-width: 200px;
    padding: 8px 0; z-index: 10;
}
.navbar__dropdown:hover .navbar__dropdown-menu { display: block; }
.navbar__dropdown-menu li a { display: block; padding: 8px 16px; color: var(--gray-700); }
.navbar__actions { display: flex; align-items: center; gap: 12px; }
.theme-toggle { background: none; border: 1px solid var(--gray-300); border-radius: 50%; width: 36px; height: 36px; cursor: pointer; display: grid; place-items: center; }
.theme-toggle__icon { width: 20px; height: 20px; display: block; background: currentColor; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='5'/%3E%3Cpath d='M12 1v2M12 21v2M4.22 4.22l1.42 1.42M18.36 18.36l1.42 1.42M1 12h2M21 12h2M4.22 19.78l1.42-1.42M18.36 5.64l1.42-1.42'/%3E%3C/svg%3E") center/contain no-repeat; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Ccircle cx='12' cy='12' r='5'/%3E%3Cpath d='M12 1v2M12 21v2M4.22 4.22l1.42 1.42M18.36 18.36l1.42 1.42M1 12h2M21 12h2M4.22 19.78l1.42-1.42M18.36 5.64l1.42-1.42'/%3E%3C/svg%3E") center/contain no-repeat; }
[data-theme="dark"] .theme-toggle__icon { mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2'%3E%3Cpath d='M21 12.79A9 9 0 1111.21 3 7 7 0 0021 12.79z'/%3E%3C/svg%3E") center/contain no-repeat; }

/* ========== HERO ========== */
.hero { position: relative; padding: 80px 0 60px; overflow: hidden; }
.hero__bg { position: absolute; inset: 0; background: linear-gradient(135deg, rgba(26,60,109,0.05), rgba(13,148,136,0.05)); z-index: -1; }
.hero__container { max-width: 1200px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 48px; }
.hero__content { flex: 1; }
.hero__title { font-size: 3.5rem; font-weight: 800; margin: 16px 0 24px; }
.hero__subtitle { font-size: 1.125rem; color: var(--gray-600); margin-bottom: 32px; max-width: 600px; }
.hero__cta { display: flex; gap: 16px; margin-bottom: 48px; }
.hero__stats { display: flex; gap: 32px; }
.hero__stat { display: flex; flex-direction: column; }
.hero__stat-number { font-size: 2rem; font-weight: 700; color: var(--royal-blue); }
.hero__visual { flex: 1; position: relative; height: 400px; }
.hero__resume-preview { position: absolute; width: 220px; height: 300px; background: white; box-shadow: var(--shadow-lg); border-radius: 8px; padding: 16px; }
.hero__resume-preview--1 { top: 20px; left: 20px; transform: rotate(-5deg); }
.hero__resume-preview--2 { top: 60px; right: 20px; transform: rotate(3deg); }
.hero__resume-preview--3 { bottom: 20px; left: 40%; transform: rotate(-2deg); }
.mini-resume__header { width: 60%; height: 12px; background: var(--royal-blue); border-radius: 4px; margin-bottom: 20px; }
.mini-resume__line { height: 8px; background: var(--gray-200); border-radius: 4px; margin-bottom: 10px; }
.mini-resume__line--lg { width: 80%; }
.mini-resume__line--md { width: 60%; }
[data-theme="dark"] .hero__resume-preview { background: var(--gray-100); }

/* ========== FEATURES, TRUSTED, SECTIONS ========== */
.features { padding: 80px 0; }
.features__container, .templates-showcase__container, .how-it-works__container, .testimonials__container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.section-header { text-align: center; margin-bottom: 64px; }
.section-header h2 { font-size: 2.5rem; font-weight: 700; margin: 12px 0; }
.section-header p { color: var(--gray-600); max-width: 600px; margin: 0 auto; }
.features__grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 32px; }
.feature-card { padding: 32px; border-radius: var(--radius-lg); border: 1px solid var(--gray-200); transition: box-shadow var(--transition); }
.feature-card:hover { box-shadow: var(--shadow-md); }
.feature-card__icon { width: 56px; height: 56px; border-radius: var(--radius-md); display: flex; align-items: center; justify-content: center; margin-bottom: 20px; }
.feature-card__icon--royal { background: rgba(26,60,109,0.1); color: var(--royal-blue); }
.feature-card__icon--teal { background: rgba(13,148,136,0.1); color: var(--teal); }
.feature-card h3 { margin-bottom: 8px; }

.templates-showcase__categories { display: flex; gap: 12px; justify-content: center; margin-bottom: 40px; flex-wrap: wrap; }
.template-cat-btn { padding: 8px 16px; border-radius: 50px; border: 1px solid var(--gray-300); background: var(--white); cursor: pointer; }
.template-cat-btn--active { background: var(--royal-blue); color: white; border-color: var(--royal-blue); }
.templates-showcase__grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 24px; }

/* ========== AUTH PAGES ========== */
.auth-main { min-height: calc(100vh - 80px); display: grid; place-items: center; padding: 40px 24px; }
.auth-container { background: var(--white); border-radius: var(--radius-lg); padding: 48px; max-width: 480px; width: 100%; box-shadow: var(--shadow-md); }
.auth-container h1 { margin-bottom: 8px; }
.auth-container p { color: var(--gray-600); margin-bottom: 32px; }
.auth-form { display: flex; flex-direction: column; gap: 20px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-weight: 500; }
.form-group input, .form-group select, .form-group textarea {
    padding: 12px 16px; border: 1px solid var(--gray-300); border-radius: var(--radius-sm);
    font: inherit; background: var(--white); color: var(--gray-900);
}
.form-group input:focus { border-color: var(--royal-blue); outline: none; box-shadow: 0 0 0 3px rgba(26,60,109,0.2); }
.form-error { color: #dc2626; font-size: 0.875rem; }
.form-hint { font-size: 0.875rem; color: var(--gray-600); }
.form-group--checkbox { flex-direction: row; align-items: center; gap: 8px; }
.form-group--checkbox input { width: 18px; height: 18px; }
.auth-alt { margin-top: 16px; }

/* ========== DASHBOARD ========== */
.dashboard-layout { display: flex; min-height: calc(100vh - 68px); }
.sidebar { width: 240px; border-right: 1px solid var(--gray-200); padding: 24px; }
.sidebar__nav ul { list-style: none; margin-top: 16px; }
.sidebar__nav li a { display: block; padding: 8px 16px; border-radius: 6px; margin-bottom: 4px; }
.sidebar__nav li a.active { background: var(--royal-blue); color: white; }
.dashboard-main { flex: 1; padding: 32px; }
.resume-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 20px; margin-top: 24px; }
.empty-state { color: var(--gray-600); margin-top: 48px; text-align: center; }

/* ========== BUILDER ========== */
.builder-layout { display: flex; height: calc(100vh - 68px); }
.builder-sidebar { width: 340px; border-right: 1px solid var(--gray-200); overflow-y: auto; padding: 20px; }
.sidebar-section { margin-bottom: 24px; }
.builder-preview { flex: 1; display: flex; flex-direction: column; }
.preview-toolbar { padding: 12px 16px; border-bottom: 1px solid var(--gray-200); display: flex; justify-content: space-between; }
.preview-pane { flex: 1; overflow-y: auto; padding: 24px; }

/* ========== FOOTER ========== */
.footer { padding: 60px 0 30px; background: var(--gray-50); border-top: 1px solid var(--gray-200); }
.footer__container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.footer__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.footer__brand-name { font-size: 1.5rem; font-weight: 800; color: var(--royal-blue); }
.footer__links ul { list-style: none; }
.footer__links li { margin-bottom: 8px; }
.footer__bottom { margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--gray-200); display: flex; justify-content: space-between; color: var(--gray-600); }
.footer__social { display: flex; gap: 16px; }

/* ========== RESPONSIVE ========== */
@media (max-width: 1024px) {
    .hero__container { flex-direction: column; }
    .builder-layout { flex-direction: column; }
    .builder-sidebar { width: 100%; max-height: 300px; border-right: none; border-bottom: 1px solid var(--gray-200); }
}
@media (max-width: 768px) {
    .navbar__toggle { display: block; }
    .navbar__menu { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--white); flex-direction: column; padding: 16px; border-bottom: 1px solid var(--gray-200); }
    .navbar__menu--open { display: flex; }
    .dashboard-layout { flex-direction: column; }
    .sidebar { width: 100%; border-right: none; border-bottom: 1px solid var(--gray-200); }
    .footer__grid { grid-template-columns: 1fr 1fr; }
}
/* Print styles, animations, etc. */
