:root {
    --primary: #1565C0;
    --primary-light: #1976D2;
    --success: #4CAF50;
    --warning: #FF9800;
    --danger: #F44336;
    --info: #2196F3;
}

body {
    background: #F5F5F5;
    padding-bottom: 70px;
}

.app-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 16px;
}

/* Top Nav */
.top-nav {
    background: var(--primary);
    color: white;
    padding: 12px 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 1030;
}
.top-nav .logo { font-weight: 700; font-size: 1.1rem; }
.top-nav .nav-actions a,
.top-nav .nav-actions button {
    color: white;
    background: none;
    border: none;
    font-size: 1.2rem;
    margin-left: 12px;
    cursor: pointer;
    text-decoration: none;
}

/* Bottom Nav */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: white;
    display: flex;
    justify-content: space-around;
    align-items: center;
    padding: 8px 0 env(safe-area-inset-bottom, 8px);
    box-shadow: 0 -2px 10px rgba(0,0,0,0.1);
    z-index: 1030;
}
.bottom-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #999;
    font-size: 0.72rem;
    padding: 4px 16px;
}
.bottom-nav a.active { color: var(--primary); }
.bottom-nav a i { font-size: 1.3rem; margin-bottom: 2px; }

/* Chips */
.chip {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
}
.chip-success { background: #E8F5E9; color: var(--success); }
.chip-warning { background: #FFF3E0; color: var(--warning); }
.chip-danger { background: #FFEBEE; color: var(--danger); }
.chip-info { background: #E3F2FD; color: var(--info); }

/* Cards custom */
.card-portal {
    border: none;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

/* Info tiles */
.info-tile {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #F0F0F0;
}
.info-tile:last-child { border-bottom: none; }
.info-tile .label { color: #757575; font-size: 0.85rem; }
.info-tile .value { font-weight: 600; color: #212121; font-size: 0.9rem; }

/* Pago item */
.pago-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 16px;
    border-bottom: 1px solid #F5F5F5;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s;
}
.pago-item:hover { background: #FAFAFA; color: inherit; }
.pago-item:last-child { border-bottom: none; }

/* Ticket item */
.ticket-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-bottom: 1px solid #F5F5F5;
    text-decoration: none;
    color: inherit;
    transition: background 0.2s;
}
.ticket-item:hover { background: #FAFAFA; color: inherit; }
.ticket-item:last-child { border-bottom: none; }
.ticket-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
}

/* Avatar */
.avatar-section { text-align: center; padding: 24px 16px; }
.avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: 700;
    position: relative;
}
.status-dot {
    position: absolute;
    bottom: 4px;
    right: 4px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 3px solid white;
}
.status-dot.active { background: var(--success); }
.status-dot.inactive { background: var(--danger); }

/* Skeleton */
.skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
    height: 20px;
    margin-bottom: 8px;
}
@keyframes shimmer {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Login */
.login-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, #0D47A1 100%);
    padding: 16px;
}
.login-card {
    background: white;
    border-radius: 20px;
    padding: 40px 30px;
    width: 100%;
    max-width: 400px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

/* FAB */
.fab {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--primary);
    color: white;
    border: none;
    font-size: 1.5rem;
    box-shadow: 0 4px 12px rgba(21, 101, 192, 0.4);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
}

/* Override Bootstrap inputs para estilo app */
.form-control-app {
    background: #FAFAFA;
    border: 1px solid #E0E0E0;
    border-radius: 10px;
    padding: 12px 16px;
}
.form-control-app:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(21, 101, 192, 0.1);
    background: white;
}

.btn-app {
    border-radius: 10px;
    padding: 12px 24px;
    font-weight: 600;
}
