/* ============================================================
   LAYOUT — Header, nav tabs, main container, section headers,
            success screen, global responsive
   ============================================================ */

/* ========== HEADER ========== */
.header { background: var(--white); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 40; }
.header-inner { max-width: 1240px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; gap: 32px; height: 78px; }
.logo { display: flex; flex-direction: column; align-items: center; gap: 0; flex-shrink: 0; }
.logo-text { font-family: 'Outfit', sans-serif; font-weight: 300; font-size: 22px; letter-spacing: 0.35em; color: var(--charcoal); text-transform: uppercase; }
.logo-text span { color: var(--gold); }
.logo-sub { font-family: 'Outfit', sans-serif; font-weight: 300; font-size: 9px; letter-spacing: 0.5em; color: var(--gold); text-transform: uppercase; margin-top: -3px; }

/* Nav Tabs — grouped (Crear / Gestionar / Operación) */
.nav-tabs { display: flex; align-items: stretch; gap: 0; }
.nav-group { display: flex; flex-direction: column; justify-content: flex-end; gap: 4px; padding: 0 22px; position: relative; }
.nav-group + .nav-group::before { content: ''; position: absolute; left: 0; top: 18%; bottom: 18%; width: 1px; background: var(--border); }
.nav-group-label { font-family: 'Outfit', sans-serif; font-size: 9px; font-weight: 500; letter-spacing: 0.25em; color: var(--muted); text-transform: uppercase; padding-left: 14px; }
.nav-group-items { display: flex; gap: 2px; }
.nav-tab { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; font-size: 13px; font-weight: 500; color: var(--muted); background: none; border: none; cursor: pointer; border-radius: 999px; transition: all 0.2s; letter-spacing: 0.02em; white-space: nowrap; }
.nav-tab:hover { color: var(--charcoal); background: var(--cream); }
.nav-tab.active { color: var(--gold); background: var(--gold-bg); }
.nav-tab svg { width: 16px; height: 16px; flex-shrink: 0; }
.nav-badge { display: inline-flex; align-items: center; justify-content: center; min-width: 22px; height: 18px; padding: 0 7px; border-radius: 999px; background: var(--gold-pale); color: var(--charcoal); font-size: 10px; font-weight: 600; letter-spacing: 0; margin-left: 2px; }
.nav-tab.active .nav-badge { background: var(--gold); color: var(--white); }
.nav-badge[hidden] { display: none; }

/* "Under construction" view for tabs not yet implemented */
.construction { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 80px 24px 60px; max-width: 520px; margin: 0 auto; }
.construction-icon { width: 64px; height: 64px; display: flex; align-items: center; justify-content: center; border-radius: 50%; background: var(--gold-bg); color: var(--gold); margin-bottom: 24px; }
.construction-icon svg { width: 30px; height: 30px; }
.construction-title { font-size: 30px; font-weight: 400; color: var(--charcoal); margin-bottom: 10px; }
.construction-text { font-size: 14px; color: var(--charcoal-light); font-weight: 400; margin-bottom: 8px; }
.construction-sub { font-size: 12px; color: var(--muted); font-weight: 300; line-height: 1.6; }

/* ========== MAIN LAYOUT ========== */
.main { max-width: 1100px; margin: 0 auto; padding: 28px 24px 80px; }
.layout { display: grid; grid-template-columns: 1fr 380px; gap: 28px; align-items: start; }
@media (max-width: 900px) { .layout { grid-template-columns: 1fr; } }
.tab-content { display: none; }
.tab-content.active { display: block; }

/* ========== SECTION HEADERS ========== */
.section-title { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; }
.section-num { font-family: 'Cormorant Garamond', serif; font-size: 13px; font-weight: 600; color: var(--gold); letter-spacing: 0.15em; text-transform: uppercase; }
.section-line { flex: 1; height: 1px; background: var(--border); }

/* ========== PAGE TITLES (used inside admin subtabs and other sections) ========== */
.page-title { font-size: 28px; font-weight: 400; color: var(--charcoal); }
.page-subtitle { font-size: 13px; color: var(--muted); font-weight: 300; margin-top: 4px; }

/* ========== SUCCESS SCREEN ========== */
.success-screen { display: none; text-align: center; max-width: 560px; margin: 0 auto; padding-top: 20px; }
.success-screen.show { display: block; }
.success-check { width: 72px; height: 72px; border-radius: 50%; background: var(--green-bg); display: flex; align-items: center; justify-content: center; margin: 0 auto 20px; }
.success-check svg { width: 32px; height: 32px; color: var(--green); }
.success-title { font-family: 'Cormorant Garamond', serif; font-size: 32px; font-weight: 400; color: var(--charcoal); margin-bottom: 6px; }
.success-subtitle { font-size: 14px; color: var(--muted); font-weight: 300; margin-bottom: 32px; }

.success-card { background: var(--white); border: 1px solid var(--border-light); border-radius: 16px; padding: 32px; text-align: left; margin-bottom: 24px; }
.success-card-title { font-family: 'Cormorant Garamond', serif; font-size: 13px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted); text-align: center; margin-bottom: 6px; }
.success-card-divider { width: 40px; height: 2px; background: var(--gold); margin: 0 auto 24px; }
.success-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-bottom: 20px; }
.success-field-label { font-size: 10px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.success-field-value { font-size: 15px; font-weight: 500; color: var(--charcoal); }
.success-field-value.gold { color: var(--gold); font-family: 'Cormorant Garamond', serif; font-size: 22px; }
.success-services { border-top: 1px solid var(--border-light); padding-top: 16px; }
.success-services-title { font-size: 10px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.success-services p { font-size: 13px; color: var(--charcoal-light); font-weight: 300; margin-bottom: 4px; padding-left: 4px; }

.success-btns { display: flex; gap: 12px; justify-content: center; margin-bottom: 20px; }
.success-btns .btn { flex: 1; max-width: 240px; }
.success-new { font-size: 13px; color: var(--muted); cursor: pointer; border: none; background: none; font-family: 'Outfit', sans-serif; letter-spacing: 0.05em; }
.success-new:hover { color: var(--gold); }

/* ========== RESPONSIVE ========== */
@media (max-width: 1100px) {
    .header-inner { gap: 16px; }
    .nav-group { padding: 0 14px; }
    .nav-tab { padding: 7px 12px; font-size: 12px; }
    .nav-group-label { padding-left: 10px; }
}
@media (max-width: 900px) {
    .header-inner { flex-direction: column; height: auto; padding: 14px 16px; gap: 14px; }
    .nav-tabs { width: 100%; justify-content: center; flex-wrap: wrap; }
    .nav-group + .nav-group::before { display: none; }
}
@media (max-width: 700px) {
    .nav-tab { padding: 6px 10px; font-size: 12px; gap: 5px; }
    .nav-tab svg { width: 14px; height: 14px; }
    .main { padding: 16px 16px 100px; }
    .card { padding: 20px; }
    .proposal { position: static; }
    .success-grid { grid-template-columns: 1fr; }
    .success-btns { flex-direction: column; }
    .success-btns .btn { max-width: 100%; }
}
