/* --- CONFIGURACIÓN BASE APP --- */
.fitlog-app {
    width: 100%;
    margin: 0 auto;
    background-color: #f8fafc;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    padding-bottom: 80px;
    overflow-x: hidden;
}

main {
    width: 100%;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

/* --- HEADER PRINCIPAL --- */
.custom-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background-color: white;
    border-bottom: 1px solid #f1f5f9;
}

.custom-header, main {
    width: 100%;
    box-sizing: border-box;
}

.brand-title {
    color: #4f46e5;
    font-size: 24px;
    font-weight: 800;
    margin: 0;
    line-height: 1.1;
}

.current-date-label {
    color: #94a3b8;
    font-size: 14px;
    margin: 0;
    text-transform: capitalize;
}

.header-controls {
    display: flex;
    gap: 12px;
}

.header-nav-btn {
    background: none;
    border: none;
    padding: 8px;
    color: #1e293b;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    border-radius: 50%;
}

.header-nav-btn:hover {
    background-color: #f1f5f9;
    color: #4f46e5;
}

.header-nav-btn:active {
    transform: scale(0.9);
}

/* --- CALENDARIO --- */
.calendar-card {
    background: white;
    margin: 8px 16px;
    border-radius: 24px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    overflow: hidden;
    display: block;
    width: auto;
    max-height: 450px;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    width: 100%;
}

.grid-header {
    background: #f8fafc;
    text-align: center;
    padding: 4px 0;
    font-size: 10px;
    font-weight: 700;
    color: #94a3b8;
    text-transform: uppercase;
}

.day-cell {
    width: 100%;
    aspect-ratio: auto;
    min-height: 80px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    position: relative;
    border: 0.5px solid #f8fafc;
    font-size: 14px;
    color: #64748b;
    cursor: pointer;
    background: none;
    padding: 10px 0;
}

.day-cell.selected {
    background: #4f46e5 !important;
    color: white !important;
    font-weight: 700;
    border-radius: 7%;
}

.dot-container {
    display: flex;
    gap: 2px;
    position: absolute;
    bottom: 2px;
    justify-content: center;
    width: 100%;
}

.dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
}

.dot-gym { background-color: #f97316; }
.dot-run { background-color: #2563eb; }
.dot-swim { background-color: #0891b2; }

.selected .dot {
    border: 0.5px solid white;
}

/* --- SECCIÓN RESUMEN --- */
.summary-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 16px;
    width: 100%;
    box-sizing: border-box;
    position: sticky;
    top: 0;
    background-color: #f8fafc;
    z-index: 10;
}

.fit-summary-container {
    flex: 1;
    overflow-y: auto;
    padding-bottom: 20px;
}

.fit-summary-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: #1a1a1a;
    margin: 0;
    text-transform: capitalize;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-right: 10px;
}

.btn-add {
    background-color: #5d3fd3;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(93, 63, 211, 0.2);
}

/* --- LISTA DE ACTIVIDADES --- */
.fit-activities-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 16px;
    width: 100%;
    box-sizing: border-box;
}

.fit-activity-card {
    background: white;
    border-radius: 20px;
    padding: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    border: 1px solid #f1f5f9;
}

/* --- PERFIL PREMIUM --- */
.profile-header-premium {
    position: relative;
    width: 100%;
    height: 180px;
    background-image: linear-gradient(rgba(15, 23, 42, 0.7), rgba(15, 23, 42, 0.95)), url('images/gym-header.png');
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 1.5rem;
    border-radius: 0 0 2rem 2rem;
    margin-top: -1px;
}

.profile-greeting-text {
    font-size: 0.8125rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 0.25rem;
}

.profile-username {
    font-size: 1.75rem;
    font-weight: 900;
    color: white;
    letter-spacing: -0.02em;
}

.badges-container {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #f1f5f9;
}

.badge-circle {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    border: 2px solid white;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.month-progress-container {
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: #f8fafc;
    border-radius: 1.5rem;
    border: 1px solid #f1f5f9;
}

.month-progress-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 1rem;
}

.month-stat-circle {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: white;
    border: 3px solid #6366f1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.15);
}

.month-stat-val {
    font-size: 0.9375rem;
    font-weight: 900;
    color: #1e293b;
    line-height: 1;
}

.month-stat-label {
    font-size: 0.625rem;
    font-weight: 700;
    color: #64748b;
}

.month-progress-info { flex: 1; }

.month-progress-desc {
    font-size: 0.75rem;
    color: #64748b;
    margin-top: 0.5rem;
    line-height: 1.4;
}

.fit-card-content {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.fit-icon-box {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.gym-bg { background-color: #FFF3E0; }
.run-bg { background-color: #E3F2FD; }
.swim-bg { background-color: #E0F2F1; }

.fit-info-section { flex-grow: 1; }

.fit-header-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.fit-type-tag { font-size: 10px; font-weight: 800; color: #7C4DFF; letter-spacing: 0.5px; }
.fit-activity-title { margin: 2px 0; font-size: 16px; font-weight: 700; color: #2D3436; }
.fit-activity-subtitle { font-size: 12px; color: #B2BEC3; margin-bottom: 8px; }

.fit-sets-display {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 8px;
}

.fit-set-pill {
    background: #F8F9FA;
    border: 1px solid #EDF2F7;
    border-radius: 8px;
    padding: 4px 10px;
    display: flex;
    gap: 8px;
    font-size: 13px;
}

.fit-set-id { color: #A0AEC0; font-style: italic; font-weight: bold; }
.fit-set-data { color: #4A5568; font-weight: 600; }
.fit-btn-delete { background: none; border: none; cursor: pointer; padding: 0; }

.fit-empty-state {
    text-align: center;
    padding: 40px;
    color: #94a3b8;
}

/* --- MODAL Y FORMULARIO --- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 16px;
    animation: fadeIn 0.3s ease-out;
}

.modal-content {
    background: white;
    width: 100%;
    max-width: 480px; 
    max-height: 90vh;
    overflow-y: auto;
    padding: 24px; /* Restored default padding for common modals */
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    animation: modalPop 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    position: relative;
}

/* Fix notifications overlapping with modals */
.rz-notification-wrapper, 
.rz-growl, 
.rz-notification {
    z-index: 10000 !important;
}

/* Responsive Utilities */
.hide-on-mobile { display: block; }
.show-on-mobile { display: none; }

@media (max-width: 500px) {
    .hide-on-mobile { display: none; }
    .show-on-mobile { display: block; }
}

/* Premium Activity Modal specific */
.modal-premium-activity {
    overflow: visible !important;
    padding: 0 !important; /* Zero padding for premium look with banner */
}

.modal-plans-padding {
    padding: 32px !important; /* Extra padding for the plans view as requested */
}

/* Horizontal Tabs for Activity Selection */
.tabs-header {
    display: flex;
    gap: 8px;
    padding: 12px 24px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    overflow-x: auto;
    scrollbar-width: none;
}

.tabs-header::-webkit-scrollbar {
    display: none;
}

.tab-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 12px;
    border: 1px solid transparent;
    background: transparent;
    color: #64748b;
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    transition: all 0.3s ease;
    cursor: pointer;
}

.tab-item:hover {
    background: #f1f5f9;
    color: #475569;
}

.tab-item.active {
    background: white;
    color: #6366f1;
    border-color: #e2e8f0;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    transform: translateY(-1px);
}

.tab-emoji {
    font-size: 1.1rem;
}

.modal-banner {
    height: 100px;
    background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%);
    border-radius: 24px 24px 0 0;
    width: 100%;
}

.modal-avatar-container {
    position: absolute;
    top: 60px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
}

.avatar-squircle {
    width: 80px;
    height: 80px;
    background: white;
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
    transform: rotate(-3deg);
}

.avatar-emoji { transform: rotate(3deg); }

.modal-header-premium {
    padding: 60px 24px 10px 24px !important;
    text-align: center;
    justify-content: center !important;
    border-bottom: none !important;
}

.modal-header-premium h3 {
    width: 100%;
    font-size: 1.5rem !important;
    font-weight: 900 !important;
    color: #1e293b;
}

.form-container {
    padding: 10px 24px 24px 24px;
    max-height: calc(90vh - 300px);
    overflow-y: auto;
    scrollbar-width: thin;
    scrollbar-color: #6366f1 transparent;
}

.form-container::-webkit-scrollbar {
    width: 6px;
}

.form-container::-webkit-scrollbar-thumb {
    background-color: #e2e8f0;
    border-radius: 10px;
}

/* Clase para modal de planes (más ancho) */
.modal-plans-wide {
    max-width: 1100px !important;
}

@keyframes modalPop {
    from { opacity: 0; transform: scale(0.9) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}

@media (min-width: 768px) {
    .modal-overlay {
        padding: 40px;
    }
}

@keyframes fadeInScale {
    from { opacity: 0; transform: scale(0.95) translateY(20px); }
    to { opacity: 1; transform: scale(1) translateY(0); }
}


.label-caps {
    font-size: 10px;
    font-weight: 800;
    color: #94a3b8;
    letter-spacing: 0.08em;
    margin-bottom: 8px;
    display: block;
}

.btn-save-full {
    width: 100%;
    background: #4f46e5;
    color: white;
    border: none;
    padding: 16px;
    border-radius: 16px;
    font-weight: 700;
    margin-top: 20px;
    cursor: pointer;
}

@keyframes slideUp {
    from { transform: translateY(100%); }
    to { transform: translateY(0); }
}

/* --- NAV INFERIOR --- */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    border-top: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-around;
    padding: 12px 0;
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: #94a3b8;
    font-size: 10px;
    font-weight: 700;
    border: none;
    background: none;
    cursor: pointer;
}

.nav-item.active { color: #4f46e5; }

/* --- FORMULARIO DINÁMICO --- */
.input-main {
    width: 100%;
    padding: 16px;
    background-color: #f8fafc;
    border-radius: 16px;
    border: none;
    box-shadow: 0 0 0 1px #e2e8f0;
    outline: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s;
    box-sizing: border-box;
}

.input-main:focus { box-shadow: 0 0 0 2px #6366f1; }
.input-readonly { background-color: #f1f5f9; color: #4f46e5; }

.grid-cols-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.grid-cols-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.space-y-3 > * + * { margin-top: 12px; }
.space-y-4 > * + * { margin-top: 16px; }
.space-y-5 > * + * { margin-top: 20px; }
.mt-4 { margin-top: 16px; }
.mt-2 { margin-top: 8px; }
.ml-1 { margin-left: 4px; }
.pt-4 { padding-top: 16px; }
.border-t-slate { border-top: 1px solid #f1f5f9; }

/* Pills */
.pill-container { display: flex; flex-wrap: wrap; gap: 8px; }

.pill {
    padding: 8px 16px;
    border-radius: 9999px;
    border: 1px solid #e2e8f0;
    font-size: 12px;
    font-weight: 600;
    background-color: white;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s;
}

.pill-selected { background-color: #4f46e5 !important; color: white !important; border-color: #4f46e5 !important; }

.pill-auto {
    background-color: #f1f5f9;
    color: #64748b;
    border: 1px solid #e2e8f0;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    cursor: default;
    display: inline-block;
}

/* Patrones */
.pattern-badge { border: 1px solid; border-radius: 8px; padding: 6px 12px; font-size: 10px; font-weight: 700; text-transform: uppercase; display: inline-block; }
.pat-empuje { background-color: #fff7ed; color: #ea580c; border-color: #ffedd5; }
.pat-traccion { background-color: #eff6ff; color: #2563eb; border-color: #dbeafe; }
.pat-flexion { background-color: #eef2ff; color: #4f46e5; border-color: #e0e7ff; }
.pat-rotacion { background-color: #faf5ff; color: #9333ea; border-color: #f3e8ff; }
.pat-estabilizacion { background-color: #f0fdf4; color: #16a34a; border-color: #dcfce7; }
.pat-activacion { background-color: #f0fdfa; color: #0d9488; border-color: #ccfbf1; }
.pat-extension { background-color: #fefce8; color: #ca8a04; border-color: #fef08a; }
.pat-pierna { background-color: #f1f5f9; color: #64748b; border-color: #e2e8f0; }
.mode-compuesto { background-color: #1e293b; color: white; border-color: #0f172a; }
.mode-aislado { background-color: #f8fafc; color: #64748b; border-color: #f1f5f9; }

/* Sets */
.flex-row-center { display: flex; align-items: center; gap: 8px; }
.w-half { width: 50%; }
.flex-1 { flex: 1; position: relative; }

.input-set-new {
    width: 100%;
    padding: 12px;
    background-color: white;
    border-radius: 12px;
    box-shadow: 0 0 0 1px #e2e8f0;
    border: none;
    text-align: center;
    font-weight: 700;
    color: #4f46e5;
    outline: none;
    box-sizing: border-box;
}

.input-set-new:focus { box-shadow: 0 0 0 2px #4f46e5; }
.input-set-new.text-slate { color: #334155; }
.input-set-new.text-cyan { color: #0891b2; }
.input-set-new.text-cyan:focus { box-shadow: 0 0 0 2px #22d3ee; }

.unit-label {
    position: absolute;
    right: 10px;
    top: 14px;
    font-size: 8px;
    font-weight: 800;
    color: #cbd5e1;
    text-transform: uppercase;
    pointer-events: none;
}

.form-box-info { padding: 16px; border-radius: 16px; text-align: center; background-color: #eef2ff; }
.form-box-info-cyan { background-color: #ecfeff; }
.form-box-label { display: block; font-size: 10px; font-weight: 700; text-transform: uppercase; margin-bottom: 4px; }
.form-box-sub { font-size: 10px; font-weight: 500; margin-top: 8px; margin-left: 4px; display: block; letter-spacing: -0.2px; }

.text-indigo { color: #818cf8; }
.text-cyan { color: #22d3ee; }
.text-indigo-bold { color: #4f46e5; font-size: 20px; font-weight: 700; }
.text-cyan-bold { color: #0891b2; font-size: 20px; font-weight: 700; }

.btn-add-dashed {
    width: 100%;
    padding: 16px;
    border: 2px dashed #e0e7ff;
    border-radius: 16px;
    color: #818cf8;
    font-size: 12px;
    font-weight: 700;
    background: transparent;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: background-color 0.2s;
    margin-top: 12px;
}

.btn-add-dashed:hover { background-color: #eef2ff; }

.btn-add-dashed-cyan {
    width: 100%;
    padding: 12px;
    border: 2px dashed #cffafe;
    border-radius: 16px;
    color: #22d3ee;
    font-size: 12px;
    font-weight: 700;
    background: transparent;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: background-color 0.2s;
    margin-top: 12px;
}

.btn-add-dashed-cyan:hover { background-color: #ecfeff; }

.set-index-square {
    background-color: #e0e7ff;
    color: #4f46e5;
    font-size: 10px;
    font-weight: 900;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-style: italic;
    flex-shrink: 0;
}

.custom-scrollbar::-webkit-scrollbar { width: 4px; }
.custom-scrollbar::-webkit-scrollbar-thumb { background: #e2e8f0; border-radius: 10px; }

.fit-badge-patt { font-size: 8px; padding: 2px 6px; background-color: #f1f5f9; color: #64748b; border-radius: 4px; font-weight: 800; text-transform: uppercase; margin-left: 6px; }
.fit-badge-muscles { font-size: 10px; color: #94a3b8; font-weight: 500; margin-top: 4px; }

/* --- HISTORIAL --- */
.view-content { display: none; width: 100%; }
.view-content.active { display: block; }
.p-4 { padding: 16px; }
.flex-grow { flex-grow: 1; }
.mb-6 { margin-bottom: 24px; }
.mb-4 { margin-bottom: 16px; }
.space-y-8 > * + * { margin-top: 32px; }

.stat-card { padding: 16px; border-radius: 24px; }
.stat-total { background-color: #4f46e5; color: white; box-shadow: 0 10px 15px -3px rgba(79, 70, 229, 0.2); }
.stat-month { background-color: white; border: 1px solid #f1f5f9; box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05); }
.stat-label { font-size: 10px; font-weight: 700; text-transform: uppercase; opacity: 0.8; }
.stat-label-light { font-size: 10px; font-weight: 700; text-transform: uppercase; color: #94a3b8; }
.stat-number { font-size: 24px; font-weight: 900; margin: 4px 0 0 0; }
.stat-number-dark { font-size: 24px; font-weight: 900; margin: 4px 0 0 0; color: #1e293b; }
.text-empty-italic { color: #94a3b8; font-style: italic; margin: 0; }

.history-date-divider { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.div-line { height: 1px; background-color: #e2e8f0; flex-grow: 1; }
.date-label-caps { font-size: 10px; font-weight: 900; text-transform: uppercase; color: #94a3b8; letter-spacing: 0.1em; }

/* Animaciones */
.animate-fade-in { animation: fadeIn 0.3s ease-out forwards; }

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

/* --- SECCIÓN PERFIL (DISEÑO PREMIUM) --- */
.rounded-profile {
    background: white;
    border-radius: 2.5rem;
    padding: 1.5rem;
    border: 1px solid #f1f5f9;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    margin-bottom: 1.5rem;
}

.rank-icon-box {
    width: 4rem;
    height: 4rem;
    background-color: #f5f3ff;
    border-radius: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.875rem;
    box-shadow: inset 0 2px 4px 0 rgba(0, 0, 0, 0.06);
}

.rank-title { font-size: 1.25rem; font-weight: 900; color: #1e293b; margin: 0; }
.rank-subtitle { font-size: 0.75rem; color: #94a3b8; font-weight: 500; }

.label-caps-indigo { font-size: 0.5625rem; font-weight: 900; color: #6366f1; text-transform: uppercase; letter-spacing: 0.1em; display: block; }
.label-caps-slate { font-size: 0.5625rem; font-weight: 900; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.1em; display: block; }
.label-caps-slate-small { font-size: 0.5rem; font-weight: 900; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.05em; }

.progress-bar-bg { background-color: #f1f5f9; border-radius: 999px; height: 8px; overflow: hidden; }
.progress-bar-fill { background: linear-gradient(90deg, #6366f1, #a855f7); height: 100%; transition: width 0.5s ease-out; }

.membership-title { font-size: 1.125rem; font-weight: 900; color: #1e293b; margin: 0; }
.badge-status { padding: 0.25rem 0.75rem; border-radius: 9999px; font-size: 0.5625rem; font-weight: 900; text-transform: uppercase; letter-spacing: 0.1em; }
.badge-green { background-color: #f0fdf4; color: #16a34a; }
.badge-yellow { background-color: #fefce8; color: #ca8a04; }
.badge-red { background-color: #fef2f2; color: #dc2626; }

.membership-info-box { background-color: #f8fafc; padding: 1rem; border-radius: 1rem; }
.membership-info-value { font-size: 0.875rem; font-weight: 900; color: #1e293b; }
.membership-info-value-indigo { font-size: 0.875rem; font-weight: 900; color: #6366f1; }

.btn-receipt {
    width: 100%;
    background: none;
    border: none;
    color: #94a3b8;
    font-size: 0.625rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    text-decoration: underline;
}

/* QR */
.qr-container { background-color: #f8fafc; padding: 1rem; border-radius: 2rem; display: inline-block; box-shadow: inset 0 2px 4px 0 rgba(0, 0, 0, 0.06); }
.qr-image { width: 10rem; height: 10rem; border-radius: 1.5rem; border: 4px solid white; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1); }
.qr-subtitle { font-size: 0.625rem; font-weight: 700; color: #94a3b8; text-transform: uppercase; letter-spacing: 0.05em; }

/* Macros */
.input-macro, .select-macro {
    width: 100%;
    padding: 1rem;
    background-color: #f8fafc;
    border-radius: 1rem;
    border: 1px solid #f1f5f9;
    font-weight: 700;
    outline: none;
    font-size: 0.875rem;
    transition: all 0.2s;
}

.input-macro:focus, .select-macro:focus { box-shadow: 0 0 0 2px #6366f1; }

.macro-result-box-indigo { background-color: #f5f3ff; padding: 1rem; border-radius: 1rem; text-align: center; }
.macro-result-box-purple { background-color: #fdf2ff; padding: 1rem; border-radius: 1rem; text-align: center; }
.label-caps-indigo-small { font-size: 0.5rem; font-weight: 900; color: #6366f1; text-transform: uppercase; }
.label-caps-purple-small { font-size: 0.5rem; font-weight: 900; color: #a855f7; text-transform: uppercase; }
.macro-result-value-indigo { font-size: 1.125rem; font-weight: 900; color: #6366f1; }
.macro-result-value-purple { font-size: 1.125rem; font-weight: 900; color: #a855f7; }

/* Biometría */
.biometry-box { display: flex; justify-content: space-between; align-items: center; padding: 1rem; background-color: #f8fafc; border-radius: 1rem; }
.biometry-label { font-size: 0.875rem; font-weight: 700; color: #1e293b; }
.biometry-value { font-size: 0.875rem; font-weight: 900; color: #6366f1; }

/* Botón de Peligro */
.btn-premium-red {
    width: 100%;
    padding: 1.25rem;
    background-color: #fef2f2;
    color: #ef4444;
    border-radius: 2rem;
    border: none;
    font-size: 0.5625rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: background-color 0.2s;
}

.btn-premium-red:hover { background-color: #fee2e2; }
.flex-row-between { display: flex; justify-content: space-between; align-items: flex-start; }

/* --- FACTURACIÓN Y RECIBOS --- */
.billing-container { animation: fadeIn 0.3s ease-out; }

.receipt-card {
    background: white;
    border-radius: 2rem;
    padding: 1.5rem;
    border: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.receipt-card:active { transform: scale(0.98); box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05); }
.receipt-info { display: flex; flex-direction: column; gap: 0.25rem; }
.receipt-title { font-size: 0.875rem; font-weight: 900; color: #1e293b; margin: 0; }
.receipt-date { font-size: 0.75rem; color: #94a3b8; font-weight: 500; }
.receipt-amount-section { text-align: right; }
.receipt-price { font-size: 1rem; font-weight: 900; color: #4f46e5; display: block; }
.status-paid { font-size: 0.625rem; font-weight: 900; color: #16a34a; text-transform: uppercase; letter-spacing: 0.05em; background-color: #f0fdf4; padding: 0.15rem 0.5rem; border-radius: 9999px; }

.btn-back-profile {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: none;
    border: none;
    color: #6366f1;
    font-size: 0.75rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    margin-bottom: 1.5rem;
    padding: 0.5rem;
    border-radius: 1rem;
    transition: background-color 0.2s;
}

.btn-back-profile:hover { background-color: #f5f3ff; }
.empty-receipts { text-align: center; padding: 3rem; color: #cbd5e1; font-style: italic; font-size: 0.875rem; }

/* --- ASISTENCIA --- */
.attendance-detail-view { animation: fadeIn 0.3s ease-out; }
.attendance-header-card { background: linear-gradient(135deg, #6366f1, #a855f7); padding: 1.5rem; border-radius: 2rem; color: white; margin-bottom: 2rem; box-shadow: 0 10px 15px -3px rgba(99, 102, 241, 0.3); }
.attendance-header-card h3 { margin: 0; font-size: 1.25rem; font-weight: 900; }
.attendance-header-card p { margin: 0.25rem 0 0 0; font-size: 0.75rem; opacity: 0.8; }
.calendar-month-box { background: white; border-radius: 1.5rem; padding: 1.25rem; border: 1px solid #f1f5f9; margin-bottom: 1.5rem; }
.month-name-label { font-size: 0.875rem; font-weight: 900; color: #1e293b; text-transform: capitalize; margin-bottom: 1rem; display: block; text-align: center; }
.attendance-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.att-grid-header { text-align: center; font-size: 0.5rem; font-weight: 900; color: #cbd5e1; text-transform: uppercase; padding-bottom: 0.5rem; }
.att-day-cell { aspect-ratio: 1/1; display: flex; align-items: center; justify-content: center; font-size: 0.75rem; font-weight: 700; color: #64748b; border-radius: 0.5rem; }
.att-day-cell.attended { background-color: #f5f3ff; color: #6366f1; position: relative; font-weight: 900; }
.att-day-cell.attended::after { content: ''; position: absolute; bottom: 4px; width: 3px; height: 3px; background-color: #6366f1; border-radius: 50%; }
.att-day-cell.outside-period { opacity: 0.2; }
.attendance-legend { display: flex; justify-content: center; gap: 1rem; margin-top: 1rem; }
.legend-item { display: flex; align-items: center; gap: 0.25rem; font-size: 0.625rem; font-weight: 700; color: #94a3b8; text-transform: uppercase; }
.legend-dot { width: 6px; height: 6px; border-radius: 50%; background-color: #6366f1; }

/* --- QR FULLSCREEN --- */
.qr-fullscreen-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0, 0, 0, 0.9); z-index: 1000; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px; backdrop-filter: blur(8px); }
.qr-large-container { background: white; padding: 24px; border-radius: 20px; box-shadow: 0 0 50px rgba(0, 0, 0, 0.5); margin-bottom: 32px; }
.qr-large-img { width: 280px; height: 280px; object-fit: contain; }
.btn-qr-close { background: #ef4444; color: white; border: none; padding: 14px 32px; border-radius: 50px; font-weight: 700; font-size: 16px; display: flex; align-items: center; gap: 10px; box-shadow: 0 10px 15px -3px rgba(239, 68, 68, 0.4); }

/* --- ANALÍTICAS --- */
.analytics-dashboard { padding: 1rem; display: flex; flex-direction: column; gap: 1.5rem; }
.analytics-card { background: white; padding: 1.25rem; border-radius: 1.5rem; border: 1px solid #f1f5f9; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02); }
.chart-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1.25rem; }
.chart-title { font-size: 0.875rem; font-weight: 800; color: #1e293b; text-transform: uppercase; letter-spacing: 0.05em; }
.bar-chart-container { display: flex; flex-direction: column; gap: 0.75rem; }
.bar-row { display: flex; align-items: center; gap: 1rem; }
.bar-label { width: 80px; font-size: 0.75rem; font-weight: 600; color: #64748b; }
.bar-track { flex: 1; height: 8px; background: #f1f5f9; border-radius: 4px; overflow: hidden; }
.bar-fill { height: 100%; background: #6366f1; border-radius: 4px; transition: width 1s ease-out; }
.pr-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.pr-card { background: #f8fafc; padding: 1rem; border-radius: 1rem; text-align: center; }
.pr-val { display: block; font-size: 1.25rem; font-weight: 900; color: #6366f1; }
.pr-label { font-size: 0.625rem; font-weight: 700; color: #94a3b8; text-transform: uppercase; }

/* =========================================
   LOGIN OFFLINE-FIRST (PREMIUM REDESIGN)
   ========================================= */
.premium-login-wrapper {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background-color: #0f172a;
    overflow: hidden;
    padding: 20px;
}

.login-bg-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(circle at top right, rgba(99, 102, 241, 0.15), transparent 50%),
                radial-gradient(circle at bottom left, rgba(16, 185, 129, 0.1), transparent 50%);
    background-color: #020617;
    z-index: 0;
}

.premium-login-card {
    position: relative;
    z-index: 10;
    width: 100%;
    max-width: 440px;
    padding: 48px 36px;
    border-radius: 28px;
    background: #11182A;
    /* Removed backdrop-filter to ensure solid color match */
    border: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
}

.login-brand-header {
    text-align: center;
    margin-bottom: 40px;
}

.brand-title-hero {
    font-size: 42px;
    font-weight: 900;
    color: #ffffff;
    letter-spacing: -1.5px;
    margin: 0 0 4px 0;
    background: linear-gradient(135deg, #c7d2fe 0%, #ffffff 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.brand-subtitle {
    color: #94a3b8;
    font-size: 16px;
    font-weight: 500;
    margin: 0;
}

.premium-label {
    display: block;
    margin-bottom: 8px;
    font-size: 13px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #cbd5e1;
}

.input-icon-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-icon {
    position: absolute;
    left: 16px;
    color: #64748b;
    pointer-events: none;
}

.input-premium {
    width: 100%;
    padding: 16px 16px 16px 48px;
    background: rgba(15, 23, 42, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #f8fafc;
    font-size: 16px;
    font-weight: 500;
    border-radius: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.input-premium::placeholder { color: #475569; }

.input-premium:focus {
    outline: none;
    border-color: #6366f1;
    background: rgba(15, 23, 42, 0.9);
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.15);
}

.btn-premium-submit {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 18px;
    background: linear-gradient(135deg, #6366f1 0%, #4f46e5 100%);
    color: white;
    font-size: 16px;
    font-weight: 700;
    border: none;
    border-radius: 16px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 10px 20px -10px rgba(99, 102, 241, 0.5);
}

.btn-premium-submit:hover:not(:disabled) { transform: translateY(-2px); box-shadow: 0 14px 28px -10px rgba(99, 102, 241, 0.6); }
.btn-premium-submit:active:not(:disabled) { transform: translateY(0); }
.btn-premium-submit:disabled { opacity: 0.7; cursor: not-allowed; background: #475569; box-shadow: none; }

.login-error-alert {
    display: flex;
    align-items: center;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: #fca5a5;
    padding: 14px 16px;
    border-radius: 12px;
    margin-bottom: 24px;
    font-size: 14px;
    font-weight: 500;
}

.login-footer-premium {
    margin-top: 32px;
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.login-footer-premium p {
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
    margin: 0;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* =========================================
   PROFILE BANNER CARD (HEADER PREMIUM)
   ========================================= */
.profile-banner-card {
    position: relative;
    width: 100%;
    height: 190px;
    background-image:
        linear-gradient(to top, rgba(15, 23, 42, 0.85) 0%, rgba(15, 23, 42, 0.3) 60%, transparent 100%),
        url('images/gym-header.png');
    background-size: cover;
    background-position: center;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 8px 30px -8px rgba(15, 23, 42, 0.3);
}

/* Botón Editar Perfil (glass pill - esquina superior derecha) */
.btn-edit-profile-glass {
    position: absolute;
    top: 14px;
    right: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: white;
    font-size: 0.6rem;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    padding: 7px 14px;
    border-radius: 9999px;
    cursor: pointer;
    transition: all 0.2s ease;
    z-index: 10;
}

.btn-edit-profile-glass:hover {
    background: rgba(255, 255, 255, 0.25);
    border-color: rgba(255, 255, 255, 0.5);
    transform: translateY(-1px);
}

/* Área inferior de la card (foto + info) */
.profile-banner-bottom {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 0 16px 16px 16px;
    display: flex;
    align-items: flex-end;
    gap: 14px;
}

/* Foto de perfil cuadrada */
.profile-avatar-box {
    width: 72px;
    height: 72px;
    border-radius: 16px;
    overflow: hidden;
    border: 3px solid rgba(255, 255, 255, 0.9);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
    flex-shrink: 0;
    background: #1e293b;
}

.profile-avatar-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #334155;
}

/* Info de nombre y badges */
.profile-banner-info {
    flex: 1;
    padding-bottom: 2px;
}

.profile-banner-badges {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 6px;
    flex-wrap: wrap;
}

/* Badge de tipo de membresía (índigo) */
.profile-badge-tier {
    font-size: 0.55rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    padding: 3px 10px;
    border-radius: 9999px;
    background: #6366f1;
    color: white;
    text-transform: uppercase;
}

/* Badge de estatus */
.profile-badge-status {
    font-size: 0.55rem;
    font-weight: 900;
    letter-spacing: 0.08em;
    padding: 3px 10px;
    border-radius: 9999px;
    text-transform: uppercase;
}

.profile-badge-active  { background: #16a34a; color: white; }
.profile-badge-prospect { background: #ca8a04; color: white; }
.profile-badge-inactive { background: #dc2626; color: white; }

/* Nombre grande en blanco */
.profile-banner-name {
    font-size: 1.5rem;
    font-weight: 900;
    color: white;
    letter-spacing: -0.02em;
    margin: 0;
    line-height: 1.1;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
}

/* =========================================
   MÓDULO ENFOQUE (FOCUS VIEW)
   ========================================= */
.focus-container {
    padding: 1rem;
    padding-bottom: 5rem;
    animation: fadeIn 0.3s ease-out;
}

/* Banner de intercambio de rutina */
.swap-routine-banner {
    background: #eef2ff;
    padding: 0.75rem 1rem;
    border-radius: 1rem;
    margin-bottom: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px dashed #6366f1;
}

.swap-text {
    font-size: 0.75rem;
    font-weight: 700;
    color: #4338ca;
}

.btn-swap-execute {
    background: #6366f1;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 0.75rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 6px -1px rgba(99, 102, 241, 0.3);
}

/* Grupos de actividad colapsables */
.activity-group-section { margin-bottom: 1rem; }

.activity-header-sticky {
    background: #f8fafc;
    padding: 0.75rem 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    border-radius: 1rem;
    border: 1px solid #f1f5f9;
    margin-bottom: 0.5rem;
    transition: all 0.25s ease;
}

.activity-header-sticky:hover { background: #f1f5f9; }

.activity-header-title {
    font-size: 0.875rem;
    font-weight: 800;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.activity-chevron {
    transition: transform 0.3s ease;
    color: #94a3b8;
}

.activity-chevron.expanded { transform: rotate(180deg); }
.activity-content { padding: 0 0.5rem; }

/* Bloques de grupos musculares */
.muscle-group-block { margin-bottom: 2rem; }

.muscle-group-header {
    font-size: 0.75rem;
    font-weight: 900;
    color: #6366f1;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.muscle-group-header::after {
    content: '';
    flex: 1;
    height: 1px;
    background: linear-gradient(to right, #e2e8f0, transparent);
}

/* Tarjeta de ejercicio */
.exercise-focus-card {
    background: white;
    border-radius: 1.5rem;
    padding: 1rem;
    border: 1px solid #f1f5f9;
    margin-bottom: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.02);
}

.exercise-main-row {
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
}

/* Checkbox personalizado */
.focus-checkbox-wrapper { position: relative; width: 24px; height: 24px; }

.focus-checkbox {
    width: 24px;
    height: 24px;
    appearance: none;
    border: 2px solid #cbd5e1;
    border-radius: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
    background: white;
}

.focus-checkbox:checked {
    background-color: #6366f1;
    border-color: #6366f1;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E");
    background-size: 14px;
    background-repeat: no-repeat;
    background-position: center;
}

/* Imagen del ejercicio */
.exercise-img {
    width: 60px;
    height: 60px;
    border-radius: 1rem;
    object-fit: cover;
    background-color: #f8fafc;
    flex-shrink: 0;
}

.exercise-desc-col { flex: 1; min-width: 0; }
.exercise-focus-title { font-size: 0.9375rem; font-weight: 800; color: #1e293b; margin: 0 0 2px 0; }
.exercise-focus-desc { font-size: 0.75rem; color: #64748b; margin: 0; line-height: 1.3; }

.btn-video-link {
    background: #f1f5f9;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #94a3b8;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
}

.btn-video-link:hover { background: #e2e8f0; color: #6366f1; }

/* Timer de descanso */
.rest-timer-box {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px dashed #f1f5f9;
}

.timer-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.btn-timer-action {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: transform 0.2s;
    flex-shrink: 0;
}

.btn-timer-play { background: #6366f1; color: white; }
.btn-timer-stop { background: #f1f5f9; color: #ef4444; }
.btn-timer-action:active { transform: scale(0.9); }

.timer-display-area { flex: 1; }

.timer-time-text {
    font-size: 0.8125rem;
    font-weight: 800;
    color: #475569;
    margin-bottom: 0.25rem;
    display: flex;
    justify-content: space-between;
}

.timer-progress-bg {
    height: 6px;
    background: #f1f5f9;
    border-radius: 999px;
    overflow: hidden;
}

.timer-progress-fill {
    height: 100%;
    background: linear-gradient(to right, #6366f1, #a855f7);
    transition: width 0.1s linear;
}

.speaker-icon { color: #94a3b8; display: flex; align-items: center; }
.speaker-icon.active { color: #6366f1; animation: pulse 1s infinite; }

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.1); }
    100% { transform: scale(1); }
}

/* Vista Detalle de Ejercicio */
.exercise-detail-view {
    padding: 1rem;
    padding-bottom: 5rem;
    animation: fadeIn 0.3s ease-out;
}

.video-placeholder-container {
    width: 100%;
    aspect-ratio: 16/9;
    background: #1e293b;
    border-radius: 2rem;
    overflow: hidden;
    position: relative;
    box-shadow: 0 20px 25px -5px rgba(0,0,0,0.1);
    margin-bottom: 2rem;
}

.video-overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.2);
}

.video-play-icon {
    width: 64px;
    height: 64px;
    background: rgba(255,255,255,0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6366f1;
    backdrop-filter: blur(4px);
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.video-placeholder-container:hover .video-play-icon { transform: scale(1.1); }

.detail-complete-btn-container {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 10;
}

.btn-detail-complete {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255,255,255,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-detail-complete.completed {
    background: #10b981;
    border-color: #10b981;
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
}

.detail-info-section { padding: 0 0.5rem; }
.detail-exercise-title { font-size: 1.5rem; font-weight: 900; color: #1e293b; margin-bottom: 0.5rem; }
.detail-exercise-desc { font-size: 0.875rem; color: #64748b; line-height: 1.6; margin-bottom: 2rem; }

.detail-timer-wrapper {
    background: #f8fafc;
    padding: 1.5rem;
    border-radius: 1.5rem;
    border: 1px solid #f1f5f9;
}

/* Inputs Premium para fondos claros */
.input-premium-dark {
    width: 100%;
    padding: 14px 16px;
    background-color: #f8fafc;
    border-radius: 14px;
    border: 1px solid #e2e8f0;
    font-size: 15px;
    font-weight: 600;
    color: #1e293b;
    outline: none;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.input-premium-dark:focus {
    border-color: #6366f1;
    background-color: white;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1);
}

.input-premium-dark::placeholder {
    color: #94a3b8;
    font-weight: 500;
}


/* =========================================
   WEEKLY STRIP (HEADER ENFOQUE)
   ========================================= */
.weekly-calendar-header {
    width: 100%;
    overflow: hidden;
}

.weekly-strip-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.weekly-day-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    flex: 1;
    min-width: 0;
    padding: 10px 4px;
    border-radius: 12px;
    background: #f8fafc;
    border: 1px solid #f1f5f9;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.weekly-day-item:active {
    transform: scale(0.95);
}

.weekly-day-item.active {
    background: #4f46e5;
    border-color: #4f46e5;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.25);
}

.weekly-day-item.is-today:not(.active) {
    border-color: #4f46e5;
    background: #f5f3ff;
}

.weekly-day-name {
    font-size: 0.65rem;
    font-weight: 800;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 2px;
}

.active .weekly-day-name {
    color: rgba(255, 255, 255, 0.8);
}

.is-today:not(.active) .weekly-day-name {
    color: #4f46e5;
}

.weekly-day-number {
    font-size: 1rem;
    font-weight: 900;
    color: #1e293b;
    line-height: 1;
}

.active .weekly-day-number {
    color: white;
}

.is-today:not(.active) .weekly-day-number {
    color: #4f46e5;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 1px solid #f1f5f9;
}

.btn-close {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    width: 2.25rem;
    height: 2.25rem;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f8fafc;
    color: #94a3b8;
    border: 1px solid #f1f5f9;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 60;
}

.btn-close:hover {
    background-color: #f1f5f9;
    color: #4f46e5;
    transform: rotate(90deg);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.btn-close:active {
    transform: scale(0.9) rotate(90deg);
}

/* --- FOCUS UPSELL (PROSPECTO) --- */
.focus-upsell-wrapper {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.focus-upsell-card {
    position: relative;
    background: linear-gradient(rgba(15, 23, 42, 0.4), rgba(15, 23, 42, 0.8)), url('https://images.unsplash.com/photo-1534438327276-14e5300c3a48?w=800&fit=crop');
    background-size: cover;
    background-position: center;
    border-radius: 48px;
    padding: 48px 24px;
    text-align: center;
    color: white;
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
    overflow: hidden;
}

.upsell-badge-elite {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
    padding: 10px 18px;
    border-radius: 100px;
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.5px;
    margin-bottom: 28px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.upsell-hero-title {
    font-size: 38px;
    font-weight: 900;
    line-height: 1.05;
    margin-bottom: 18px;
    letter-spacing: -1.5px;
}

.upsell-hero-desc {
    font-size: 15px;
    color: rgba(255,255,255,0.85);
    max-width: 340px;
    margin: 0 auto 36px auto;
    line-height: 1.5;
    font-weight: 500;
}

.btn-focus-activate {
    width: 100%;
    max-width: 310px;
    background: white;
    color: #4f46e5;
    border: none;
    padding: 18px;
    border-radius: 100px;
    font-size: 13px;
    font-weight: 900;
    letter-spacing: 1.5px;
    transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
    cursor: pointer;
    text-transform: uppercase;
    margin: 0 auto;
    display: block;
}

.btn-focus-activate:hover {
    transform: translateY(-3px) scale(1.02);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1);
}

.locked-routine-section {
    padding: 0 8px;
}

.locked-section-title {
    font-size: 22px;
    font-weight: 900;
    color: #0f172a;
    margin-bottom: 32px;
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: -0.5px;
}

.locked-content-pill {
    background: white;
    border-radius: 32px;
    padding: 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 18px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.03);
    color: #0f172a;
    font-weight: 900;
    font-size: 13px;
    letter-spacing: 1.5px;
    border: 1px solid #f1f5f9;
}

.locked-icon-btn {
    width: 60px;
    height: 60px;
    background: #f5f3ff;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- HISTORY UPSELL (PROSPECTO) --- */
.history-upsell-container {
    background: #0f172a;
    padding: 60px 40px;
    text-align: center;
    position: relative;
    border-radius: 42px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    margin: 10px 0;
}

.history-upsell-star {
    position: absolute;
    right: -10px;
    top: 0;
    color: rgba(255, 255, 255, 0.08);
    transform: rotate(15deg);
    z-index: 1;
    pointer-events: none;
}

.history-upsell-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.history-upsell-title {
    color: white;
    font-size: 2.2rem;
    font-weight: 950;
    margin-bottom: 8px;
    letter-spacing: -1.5px;
    font-family: 'Outfit', sans-serif;
}

.history-upsell-subtitle {
    color: #94a3b8;
    font-size: 0.75rem;
    font-weight: 800;
    margin-bottom: 42px;
    letter-spacing: 1.8px;
    text-transform: uppercase;
}

.history-upsell-subtitle-long {
    color: #94a3b8;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 38px;
    line-height: 1.5;
    max-width: 320px;
    opacity: 0.85;
}

.history-upsell-btn {
    background: #6366f1;
    color: white;
    font-weight: 950;
    font-size: 0.95rem;
    padding: 1.2rem 3.5rem;
    border-radius: 100px;
    border: none;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    box-shadow: 0 15px 35px -5px rgba(99, 102, 241, 0.45);
    margin-bottom: 24px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.history-upsell-btn:active { transform: scale(0.96); }

.history-upsell-footer {
    color: rgba(255, 255, 255, 0.22);
    font-size: 0.62rem;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* --- LOCKED CHART (HISTORY) --- */
.locked-chart-placeholder {
    min-height: 190px;
    display: flex;
    flex-direction: column;
    padding: 24px 8px 8px 8px;
    position: relative;
    background: white;
}

.lock-icon-bg {
    color: #1e293b;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.lock-action-text {
    color: #0f172a;
    font-size: 0.8rem;
    font-weight: 950;
    letter-spacing: 1.2px;
    font-family: 'Outfit', sans-serif;
    text-transform: uppercase;
}

.lock-chart-footer {
    margin-top: auto;
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding-top: 18px;
}

.lock-chart-footer span {
    color: #cbd5e1;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

/* --- PREMIUM LOCKED CHART (HISTORY) --- */
.locked-chart-placeholder-premium {
    background: #0f172a;
    min-height: 200px;
    border-radius: 42px;
    display: flex;
    flex-direction: column;
    padding: 2.5rem 2rem 1.25rem 2rem;
    position: relative;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    margin: 4px 0;
}

.lock-premium-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
}

.lock-premium-icon {
    color: white;
    margin-bottom: 1rem;
    opacity: 0.9;
    display: flex;
    align-items: center;
}

.lock-premium-text {
    color: white;
    font-size: 0.85rem;
    font-weight: 950;
    letter-spacing: 1.5px;
    font-family: 'Outfit', sans-serif;
    text-transform: uppercase;
}

.lock-premium-footer {
    display: flex;
    justify-content: space-between;
    width: 100%;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.lock-premium-footer span {
    color: rgba(255, 255, 255, 0.25);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 1.2px;
    text-transform: uppercase;
}
/* === Loading spinner === */
@keyframes spin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}
.animate-spin { animation: spin 0.8s linear infinite; }


/* === Completed Exercise State === */
.exercise-done { border-color: #10b981 !important; background: #f0fdf4 !important; transition: all 0.3s ease; }
.focus-checkbox-done { width: 24px; height: 24px; border-radius: 50%; background: #10b981; display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 4px rgba(16,185,129,0.3); }

