/** ============================================
 * Dia dos Pais CPA — Style Refactored
 * Colégio Pouso Alegre — 2026
 * Design moderno, clean e atrativo
 * ============================================ */

/* === FONTS & RESET === */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700;800&display=swap');

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

/* === CSS CUSTOM PROPERTIES === */
:root {
    --primary: #E8734A;       /* laranja-pêssego, mais acolhedor */
    --primary-light: #FF9A70;
    --primary-dark: #D0603A;
    --secondary: #2B3A67;
    --accent: #F4C542;
    --accent-light: #FFE08A;
    --success: #27AE60;
    --success-bg: #E8F8EF;
    --danger: #E74C3C;
    --danger-bg: #FDEDEC;
    --warning: #F39C12;
    --warning-bg: #FEF9E7;
    --bg: #FAF8F5;
    --bg-card: #FFFFFF;
    --text: #2D2D2D;
    --text-light: #6B6B6B;
    --text-lighter: #999;
    --border: #E8E2DC;
    --shadow-sm: 0 1px 3px rgba(0,0,0,0.06);
    --shadow: 0 4px 16px rgba(0,0,0,0.08);
    --shadow-lg: 0 12px 40px rgba(0,0,0,0.12);
    --radius: 12px;
    --radius-lg: 20px;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

/* === CONTAINER === */
.container {
    max-width: 860px;
    margin: 0 auto;
    padding: 1.5rem;
}

/* === TOP BAR — Logo do Colégio === */
.top-bar {
    text-align: center;
    padding: 1.25rem 1rem 0.75rem;
}
.top-bar img {
    max-width: 260px;
    max-height: 80px;
    width: auto;
    height: auto;
    object-fit: contain;
    opacity: 0.9;
}
.top-bar p {
    font-size: 0.75rem;
    color: var(--text-light);
    letter-spacing: 2px;
    text-transform: uppercase;
    font-weight: 600;
    margin-top: 4px;
}

/* === HERO PRINCIPAL (compacto, informação acionável no topo) === */
.hero {
    position: relative;
    background: linear-gradient(135deg, var(--primary), var(--primary-light), var(--primary-dark));
    color: #fff;
    text-align: center;
    padding: 2rem 1.5rem;
    border-radius: var(--radius-lg);
    margin-bottom: 2rem;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -30%;
    width: 300px;
    height: 300px;
    background: rgba(255,255,255,0.06);
    border-radius: 50%;
    pointer-events: none;
}

.hero::after {
    content: '';
    position: absolute;
    bottom: -40%;
    left: -20%;
    width: 250px;
    height: 250px;
    background: rgba(255,255,255,0.04);
    border-radius: 50%;
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-icon {
    font-size: 2.8rem;
    display: block;
    margin-bottom: 0.5rem;
}

.hero h1 {
    font-size: 1.6rem;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 0.3rem;
    line-height: 1.2;
}

.hero-date {
    display: inline-block;
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(4px);
    padding: 0.4rem 1.2rem;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0.75rem 0;
}

.hero p {
    font-size: 1rem;
    opacity: 0.92;
    max-width: 500px;
    margin: 0.3rem auto 0;
}

.hero-pills {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0.4rem;
    margin: 0.75rem 0 0.5rem;
}
.hero-pill {
    background: rgba(255,255,255,0.2);
    backdrop-filter: blur(4px);
    padding: 0.35rem 0.9rem;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* Hero pequeno (painel) */
.hero-small {
    padding: 1.5rem 1.25rem;
    margin-bottom: 1.5rem;
}
.hero-small h1 { font-size: 1.3rem; }

/* === CARDS GENÉRICOS === */
.card {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 2rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border);
    transition: box-shadow var(--transition);
}
.card:hover {
    box-shadow: var(--shadow-lg);
}

.card h2 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 1rem;
}

/* === INFO BOX (seção de informações) — removida, info foi pro hero pills === */
/* Mantida para padding/fallback, não usada na index */

/* === FORMULÁRIO === */
.form-section {
    background: var(--bg-card);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 2rem;
    border: 1px solid var(--border);
}

.form-section h2 {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.3rem;
    color: var(--secondary);
    margin-bottom: 0.5rem;
}

.form-section .subtitle {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.4rem;
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--secondary);
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 0.95rem;
    font-family: inherit;
    transition: all var(--transition);
    background: #FCFAF8;
}

.form-group input:focus {
    border-color: var(--primary);
    outline: none;
    box-shadow: 0 0 0 4px rgba(232, 115, 74, 0.12);
    background: #fff;
}

.form-group input::placeholder {
    color: #BBB;
}

.checkbox-group {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    padding: 0.75rem 1rem;
    background: #FCFAF8;
    border-radius: 10px;
    border: 1px solid var(--border);
    transition: all var(--transition);
    cursor: pointer;
}

.checkbox-group:hover {
    border-color: var(--primary-light);
    background: #FFF8F5;
}

.checkbox-group label {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    font-weight: 500 !important;
    cursor: pointer;
    font-size: 0.9rem;
    color: var(--text);
    line-height: 1.4;
}

.checkbox-group input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    accent-color: var(--primary);
    flex-shrink: 0;
    cursor: pointer;
}

.checkbox-group a {
    color: var(--primary);
    font-weight: 600;
}

/* === BOTÕES === */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.7rem 1.4rem;
    font-size: 0.9rem;
    font-weight: 700;
    font-family: inherit;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    transition: all var(--transition);
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: #fff;
    box-shadow: 0 4px 14px rgba(232, 115, 74, 0.35);
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(232, 115, 74, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
}

.btn-secondary {
    background: var(--secondary);
    color: #fff;
    box-shadow: 0 4px 14px rgba(43, 58, 103, 0.3);
}

.btn-secondary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(43, 58, 103, 0.35);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
}

.btn-outline:hover {
    background: var(--primary);
    color: #fff;
}

.btn-text {
    background: none;
    color: var(--primary);
    padding: 0.5rem;
    text-decoration: underline;
    font-weight: 600;
}

.btn-block {
    width: 100%;
    justify-content: center;
}

.btn-danger {
    background: var(--danger);
    color: #fff;
}
.btn-danger:hover {
    background: #C0392B;
    transform: translateY(-2px);
}

/* Botão pequeno (painel) */
.btn-sm {
    padding: 0.45rem 0.9rem;
    font-size: 0.8rem;
    border-radius: 8px;
    background: var(--primary);
    color: #fff;
    border: none;
    cursor: pointer;
    font-family: inherit;
    font-weight: 600;
    transition: all var(--transition);
}
.btn-sm:hover {
    background: var(--primary-dark);
}

/* === ALERTAS === */
.alert {
    padding: 1rem 1.25rem;
    border-radius: 10px;
    margin-bottom: 1rem;
    font-weight: 500;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}
.alert-error {
    background: var(--danger-bg);
    color: #922B21;
    border: 1px solid #F5B7B1;
}
.alert-success {
    background: var(--success-bg);
    color: #1E8449;
    border: 1px solid #A9DFBF;
}
.alert-warning {
    background: var(--warning-bg);
    color: #7D6608;
    border: 1px solid #F9E79F;
}

/* === PAYMENT === */
.payment-card {
    background: var(--bg-card);
    padding: 2rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.payment-card h2 {
    color: var(--secondary);
    margin-bottom: 1rem;
}

.order-details {
    background: #FCFAF8;
    border-radius: 10px;
    padding: 1.25rem;
}

.order-details p {
    margin-bottom: 0.6rem;
    font-size: 0.95rem;
    display: flex;
    justify-content: space-between;
}

.order-amount {
    font-size: 1.4rem !important;
    font-weight: 800;
    color: var(--primary);
    border-top: 1px solid var(--border);
    padding-top: 0.75rem;
    margin-top: 0.5rem;
}

.payment-actions {
    margin-top: 1.5rem;
    text-align: center;
}

.payment-info {
    margin-top: 1rem;
    font-size: 0.8rem;
    color: var(--text-lighter);
    text-align: center;
}

/* === PANEL === */
.panel-section {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.panel-card {
    background: var(--bg-card);
    padding: 1.5rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
}

.panel-card h2 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--secondary);
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.info-table {
    width: 100%;
    border-collapse: collapse;
}

.info-table tr:last-child td {
    border-bottom: none;
}

.info-table td {
    padding: 0.7rem 0;
    border-bottom: 1px solid #F0EBE6;
    font-size: 0.9rem;
}

.info-table td:first-child {
    color: var(--text-light);
    width: 40%;
    font-weight: 600;
}

.info-table td:last-child {
    color: var(--text);
    font-weight: 500;
}

/* Status badges */
.status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 1.25rem;
    border-radius: 50px;
    font-weight: 700;
    font-size: 0.85rem;
    margin-bottom: 1rem;
}
.status-pending {
    background: var(--warning-bg);
    color: #7D6608;
    border: 1px solid #F9E79F;
}
.status-approved {
    background: var(--success-bg);
    color: #1E8449;
    border: 1px solid #A9DFBF;
}
.status-rejected {
    background: var(--danger-bg);
    color: #922B21;
    border: 1px solid #F5B7B1;
}

.panel-actions {
    display: flex;
    gap: 0.75rem;
    align-items: center;
    flex-wrap: wrap;
    margin-top: 0.5rem;
}

/* === FOOTER === */
.site-footer {
    text-align: center;
    padding: 2.5rem 0 1.5rem;
    color: var(--text-lighter);
    font-size: 0.8rem;
    border-top: 1px solid var(--border);
    margin-top: 2rem;
}
.site-footer a {
    color: var(--primary);
    text-decoration: none;
    font-weight: 600;
}
.site-footer a:hover {
    text-decoration: underline;
}
.site-footer .copy {
    margin-top: 0.5rem;
    opacity: 0.7;
}

/* === LOGIN FORM SPECIFIC === */
.login-card {
    max-width: 420px;
    margin: 0 auto;
}

/* === ANIMAÇÕES — apenas 1 elemento, sem cascade === */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-in {
    animation: fadeUp 0.4s ease-out both;
}

/* Apenas o primeiro .animate-in recebe animação — evita delay cascade */
.animate-in:first-of-type {
    animation-delay: 0.05s;
}
.animate-in:not(:first-of-type) {
    animation: none;
    opacity: 1;
}

/* === RESPONSIVE === */
@media (max-width: 600px) {
    .container { padding: 1rem; }
    .hero { padding: 1.5rem 1.25rem; border-radius: 16px; }
    .hero h1 { font-size: 1.35rem; }
    .hero-icon { font-size: 2.2rem; }
    .card, .form-section, .panel-card { padding: 1.25rem; }
    .info-table td:first-child { width: 45%; }
    .btn { padding: 0.65rem 1.1rem; font-size: 0.85rem; }
    .panel-actions { flex-direction: column; }
    .panel-actions .btn { width: 100%; text-align: center; }
}
