:root {
    --bg-champagne: #FDFBF7;
    --bg-soft: #F5F0E1;
    --accent-gold: #C5A059;
    --dark-brown: #3D2B1F;
    --text-muted: #6B5B51;
    --white: #FFFFFF;
    --green: #5B8C6E;
    --yellow: #D9A441;
    --red: #C66B5A;
    --shadow: 0 10px 30px rgba(61, 43, 31, 0.10);
}

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

html { scroll-behavior: smooth; }

body {
    font-family: 'Outfit', sans-serif;
    background-color: var(--bg-champagne);
    color: var(--dark-brown);
    line-height: 1.6;
}

h1, h2, h3, .logo { font-family: 'Playfair Display', serif; font-weight: 700; }

/* ---------- TOP NAV ---------- */
header {
    background: rgba(253, 251, 247, 0.9);
    backdrop-filter: blur(12px);
    position: fixed;
    width: 100%;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(197, 160, 89, 0.2);
}

nav {
    max-width: 1200px;
    margin: 0 auto;
    height: 68px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    gap: 16px;
}

.logo { font-size: 22px; letter-spacing: 2px; white-space: nowrap; }
.logo .growth { color: var(--accent-gold); font-style: italic; margin-left: 4px; }

.nav-tabs { display: flex; gap: 6px; flex-wrap: wrap; }

.nav-tabs button {
    background: transparent;
    border: none;
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    font-size: 14px;
    color: var(--text-muted);
    padding: 8px 14px;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.25s ease;
}

.nav-tabs button:hover { color: var(--dark-brown); background: var(--bg-soft); }
.nav-tabs button.active { background: var(--dark-brown); color: var(--white); }

.nav-user { display: flex; align-items: center; gap: 12px; font-size: 14px; font-weight: 600; color: var(--text-muted); white-space: nowrap; }
.nav-user a { color: var(--dark-brown); text-decoration: none; font-weight: 700; }
.nav-user a:hover { color: var(--accent-gold); }

/* ---------- LAYOUT / SLIDES ---------- */
main { max-width: 1100px; margin: 0 auto; padding: 108px 24px 140px; }
main.no-footer { padding-bottom: 60px; }

.slide { display: none; animation: fade 0.4s ease; }
.slide.active { display: block; }

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

.badge {
    background: rgba(197, 160, 89, 0.12);
    color: var(--accent-gold);
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 12px;
    font-weight: 800;
    letter-spacing: 2px;
    display: inline-block;
    margin-bottom: 18px;
}

h1.title { font-size: 46px; line-height: 1.12; margin-bottom: 18px; }
h1.title .accent { color: var(--accent-gold); }
.slide h1 { font-size: 46px; line-height: 1.12; margin-bottom: 18px; }
.slide h1 .accent { color: var(--accent-gold); }
.slide h2, .card h2 { font-size: 30px; margin: 32px 0 14px; }
.card h2 { margin-top: 0; }
.lead { font-size: 19px; color: var(--text-muted); max-width: 760px; margin-bottom: 24px; }

.card {
    background: var(--white);
    border: 1px solid rgba(197, 160, 89, 0.15);
    border-radius: 24px;
    padding: 32px;
    box-shadow: var(--shadow);
    margin-bottom: 24px;
}

.objective {
    background: var(--bg-soft);
    border-left: 5px solid var(--accent-gold);
    border-radius: 12px;
    padding: 18px 22px;
    margin-bottom: 24px;
    font-size: 16px;
}
.objective strong { color: var(--dark-brown); }

.quote {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    font-size: 21px;
    color: var(--dark-brown);
    border-top: 1px solid var(--bg-soft);
    padding-top: 22px;
    margin-top: 8px;
}
.quote::before { content: '“'; color: var(--accent-gold); font-size: 30px; }
.quote::after { content: '”'; color: var(--accent-gold); font-size: 30px; }

.pill-row { display: flex; gap: 10px; flex-wrap: wrap; margin: 16px 0; }
.pill {
    background: var(--bg-soft); color: var(--dark-brown);
    padding: 8px 16px; border-radius: 50px; font-size: 14px; font-weight: 600;
}

/* ---------- ACTIVITY CARDS ---------- */
.activity-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 32px; }
.act-card {
    background: var(--white); border-radius: 24px; padding: 28px;
    border: 1px solid rgba(197, 160, 89, 0.15); box-shadow: var(--shadow);
    cursor: pointer; transition: transform 0.25s ease, border-color 0.25s ease;
}
.act-card:hover { transform: translateY(-8px); border-color: var(--accent-gold); }
.act-card .num { font-family: 'Playfair Display', serif; font-size: 40px; color: var(--accent-gold); }
.act-card h3 { font-size: 20px; margin: 8px 0 10px; }
.act-card p { font-size: 14px; color: var(--text-muted); }

/* ---------- TABLES / INPUTS ---------- */
table { width: 100%; border-collapse: collapse; margin-top: 8px; }
th, td { text-align: left; padding: 10px; border-bottom: 1px solid var(--bg-soft); font-size: 14px; vertical-align: middle; }
th { font-weight: 800; color: var(--dark-brown); font-size: 13px; text-transform: uppercase; letter-spacing: 0.5px; }

input[type="text"], input[type="number"], input[type="email"], input[type="password"], textarea, select {
    font-family: 'Outfit', sans-serif;
    width: 100%;
    border: 1px solid rgba(197, 160, 89, 0.25);
    border-radius: 10px;
    padding: 9px 12px;
    font-size: 14px;
    color: var(--dark-brown);
    background: var(--bg-champagne);
    transition: border-color 0.2s ease;
}
input:focus, textarea:focus, select:focus { outline: none; border-color: var(--accent-gold); background: var(--white); }
textarea { resize: vertical; min-height: 46px; }

label { font-weight: 600; font-size: 14px; display: block; margin: 14px 0 6px; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.btn {
    background: var(--accent-gold); color: var(--white); border: none;
    font-family: 'Outfit', sans-serif; font-weight: 700; font-size: 14px;
    padding: 12px 22px; border-radius: 50px; cursor: pointer;
    transition: all 0.25s ease; box-shadow: 0 8px 18px rgba(197, 160, 89, 0.3);
}
.btn:hover { transform: translateY(-2px); }
.btn.ghost { background: transparent; color: var(--dark-brown); border: 1px solid var(--accent-gold); box-shadow: none; }
.btn.small { padding: 8px 16px; font-size: 13px; }
.btn.block { width: 100%; padding: 14px; font-size: 15px; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; transform: none; }
.btn-row { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 18px; }

.row-del { background: none; border: none; color: var(--red); cursor: pointer; font-size: 18px; font-weight: 800; }

/* type select color coding (Módulo 1) */
select.type-O { color: var(--red); font-weight: 700; }
select.type-A { color: var(--yellow); font-weight: 700; }
select.type-E { color: var(--green); font-weight: 700; }

/* summary boxes */
.summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-top: 20px; }
.sum-box { background: var(--bg-soft); border-radius: 16px; padding: 20px; text-align: center; }
.sum-box .big { font-size: 32px; font-weight: 800; font-family: 'Playfair Display', serif; color: var(--accent-gold); }
.sum-box.O .big { color: var(--red); }
.sum-box.A .big { color: var(--yellow); }
.sum-box.E .big { color: var(--green); }
.sum-box .lbl { font-size: 13px; color: var(--text-muted); font-weight: 600; }

/* score buttons (Módulo 1) */
.score-group { display: inline-flex; gap: 4px; }
.score-group button {
    width: 34px; height: 34px; border-radius: 8px; border: 1px solid rgba(197,160,89,0.3);
    background: var(--bg-champagne); cursor: pointer; font-weight: 700; color: var(--text-muted);
    font-family: 'Outfit', sans-serif; transition: all 0.15s ease;
}
.score-group button.sel { background: var(--accent-gold); color: var(--white); border-color: var(--accent-gold); }

.checklist { list-style: none; margin-top: 8px; }
.checklist li { display: flex; align-items: flex-start; gap: 12px; padding: 8px 0; font-size: 15px; }
.checklist input[type="checkbox"] { width: 20px; height: 20px; margin-top: 3px; accent-color: var(--accent-gold); cursor: pointer; flex-shrink: 0; }

/* bio preview (Módulo 2) */
.bio-preview {
    background: var(--bg-soft);
    border-radius: 16px;
    padding: 22px;
    margin-top: 18px;
    font-size: 15px;
    white-space: pre-line;
    border: 1px dashed var(--accent-gold);
}
.bio-preview .ph { color: var(--text-muted); font-style: italic; }

/* ---------- FOOTER NAV ---------- */
.footer-nav {
    position: fixed; bottom: 0; left: 0; width: 100%;
    background: rgba(253, 251, 247, 0.92); backdrop-filter: blur(12px);
    border-top: 1px solid rgba(197, 160, 89, 0.2);
    display: flex; align-items: center; justify-content: space-between;
    padding: 14px 24px; z-index: 1000;
}
.footer-nav .progress { flex: 1; margin: 0 24px; height: 6px; background: var(--bg-soft); border-radius: 10px; overflow: hidden; }
.footer-nav .progress span { display: block; height: 100%; background: var(--accent-gold); transition: width 0.4s ease; width: 20%; }
.step-label { font-size: 13px; color: var(--text-muted); font-weight: 600; white-space: nowrap; }

.save-hint { font-size: 12px; color: var(--text-muted); font-style: italic; margin-top: 10px; }

/* ---------- LOGIN ---------- */
.auth-wrap {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: radial-gradient(circle at top right, var(--bg-soft), var(--bg-champagne));
}
.auth-card {
    width: 100%;
    max-width: 440px;
    background: var(--white);
    border-radius: 28px;
    padding: 44px 40px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(197, 160, 89, 0.15);
}
.auth-card .logo { font-size: 26px; text-align: center; display: block; margin-bottom: 6px; }
.auth-sub { text-align: center; color: var(--text-muted); font-size: 14px; margin-bottom: 26px; }
.auth-tabs { display: flex; background: var(--bg-soft); border-radius: 50px; padding: 4px; margin-bottom: 22px; }
.auth-tabs button {
    flex: 1; border: none; background: transparent; padding: 10px;
    border-radius: 50px; font-family: 'Outfit', sans-serif; font-weight: 700;
    font-size: 14px; color: var(--text-muted); cursor: pointer; transition: all 0.25s ease;
}
.auth-tabs button.active { background: var(--dark-brown); color: var(--white); }
.auth-error {
    background: rgba(198, 107, 90, 0.12); color: var(--red);
    border-radius: 10px; padding: 10px 14px; font-size: 13px; font-weight: 600;
    margin-top: 14px; display: none;
}
.auth-error.show { display: block; }

/* ---------- DASHBOARD ---------- */
.mod-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 28px; }
.mod-card {
    background: var(--white); border-radius: 24px; padding: 28px;
    border: 1px solid rgba(197, 160, 89, 0.15); box-shadow: var(--shadow);
    display: flex; flex-direction: column; gap: 10px;
    transition: transform 0.25s ease, border-color 0.25s ease;
}
.mod-card.activo { cursor: pointer; }
.mod-card.activo:hover { transform: translateY(-6px); border-color: var(--accent-gold); }
.mod-card.locked { opacity: 0.55; background: var(--bg-champagne); }
.mod-card .mod-num {
    font-size: 11px; font-weight: 800; letter-spacing: 2px; color: var(--accent-gold);
    text-transform: uppercase;
}
.mod-card h3 { font-size: 21px; line-height: 1.25; }
.mod-card p { font-size: 14px; color: var(--text-muted); flex: 1; }
.prog { height: 8px; background: var(--bg-soft); border-radius: 10px; overflow: hidden; }
.prog span { display: block; height: 100%; background: var(--accent-gold); transition: width 0.5s ease; }
.prog-label { font-size: 12px; font-weight: 700; color: var(--text-muted); display: flex; justify-content: space-between; }
.lesson-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 4px; }
.lesson-chip {
    font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 50px;
    background: var(--bg-soft); color: var(--text-muted);
}
.lesson-chip.done { background: rgba(91, 140, 110, 0.15); color: var(--green); }
.lesson-chip.mid { background: rgba(217, 164, 65, 0.15); color: var(--yellow); }
.mod-updated { font-size: 11px; color: var(--text-muted); font-style: italic; }

@media (max-width: 900px) {
    .activity-grid, .summary, .mod-grid { grid-template-columns: 1fr; }
    .field-grid { grid-template-columns: 1fr; }
    .slide h1, h1.title { font-size: 34px; }
    .nav-tabs { display: none; }
    .nav-user span.email { display: none; }
}

/* ---------- PRINT ---------- */
@media print {
    header, .footer-nav, .btn-row, .nav-tabs { display: none !important; }
    .slide { display: block !important; page-break-after: always; }
    main { padding: 0; max-width: 100%; }
}
