/* =============================================
   FRONT-END CSS - Plataforma de Concursos Públicos
   ============================================= */

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

:root {
    --primary: #CC0000;
    --primary-dark: #a30000;
    --primary-light: #fce8e8;
    --secondary: #F5A623;
    --success: #0e9f6e;
    --warning: #f59e0b;
    --danger: #e02424;
    --info: #3f83f8;
    --dark: #111111;
    --gray-100: #f3f4f6;
    --gray-200: #e5e7eb;
    --gray-300: #d1d5db;
    --gray-400: #9ca3af;
    --gray-500: #6b7280;
    --gray-600: #4b5563;
    --gray-700: #374151;
    --white: #ffffff;
    --radius: 8px;
    --radius-lg: 12px;
    --shadow: 0 1px 3px rgba(0,0,0,0.12);
    --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px rgba(0,0,0,0.12);
    --transition: all 0.3s ease;
    --max-width: 1200px;
}

body {
    font-family: 'Tahoma', 'Segoe UI', sans-serif;
    font-size: 15px; color: var(--dark); background: var(--gray-100);
    line-height: 1.6;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-dark); }

img { max-width: 100%; height: auto; }

.container { max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }

/* =============================================
   HEADER / NAVIGATION
   ============================================= */
.site-header {
    background: var(--white); box-shadow: var(--shadow);
    position: sticky; top: 0; z-index: 1000;
}

.gov-strip {
    background: linear-gradient(90deg, #fffdfd 0%, #000000 100%);
    color: rgba(255,255,255,0.9);
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.gov-strip-inner {
    min-height: 48px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.77rem;
}

.gov-strip-inner i { color: var(--secondary); margin-right: 6px; }

.gov-strip-links {
    display: flex;
    align-items: center;
    gap: 16px;
}

.gov-strip-links a {
    color: rgba(255,255,255,0.86);
    font-weight: 600;
    letter-spacing: 0.2px;
}

.gov-strip-links a:hover { color: #fff; }

.header-inner {
    max-width: var(--max-width); margin: 0 auto; padding: 0 20px;
    display: flex; align-items: center; justify-content: space-between; height: 78px;
}

.logo { display: flex; align-items: center; gap: 12px; color: var(--dark); }
.logo-mark {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: radial-gradient(circle at 35% 30%, #e60000 0%, #a30000 70%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    box-shadow: 0 0 0 3px rgba(176,139,47,0.22);
}

.logo-text {
    display: flex;
    flex-direction: column;
    line-height: 1.15;
}

.logo-text small {
    font-size: 0.69rem;
    color: var(--gray-500);
    text-transform: uppercase;
    letter-spacing: 0.6px;
}

.logo-text strong {
    margin-top: 2px;
    font-size: 1rem;
    color: var(--primary);
    font-weight: 800;
    letter-spacing: 0.2px;
}

.logo:hover { color: var(--primary); }

.main-nav { display: flex; align-items: center; gap: 6px; }
.main-nav a {
    padding: 10px 14px;
    color: var(--gray-600);
    font-weight: 700;
    border-radius: var(--radius);
    font-size: 0.82rem;
    transition: var(--transition);
    text-transform: uppercase;
    letter-spacing: 0.4px;
}
.main-nav a:hover { color: var(--primary); background: var(--primary-light); }
.main-nav a.active {
    color: var(--white);
    background: linear-gradient(135deg, #CC0000 0%, #a30000 100%);
    box-shadow: var(--shadow);
}

.header-actions { display: flex; align-items: center; gap: 8px; }
.logout-btn { border-color: #b91c1c; color: #b91c1c; font-weight: 700; transition: background-color .2s ease, color .2s ease, box-shadow .2s ease, transform .2s ease; }
.logout-btn:hover { background: #b91c1c; color: #fff; box-shadow: 0 4px 12px rgba(185, 28, 28, .2); transform: translateY(-1px); }
.logout-btn:focus-visible, .logout-nav-btn:focus-visible { outline: 3px solid rgba(185, 28, 28, .25); outline-offset: 2px; }

.mobile-toggle { display: none; background: none; border: none; font-size: 1.4rem; color: var(--gray-600); cursor: pointer; padding: 8px; }

/* =============================================
   HERO
   ============================================= */
.hero {
    background: linear-gradient(130deg, #CC0000 0%, #880000 55%, #F5A623 160%);
    color: var(--white); padding: 80px 0; text-align: center;
}

.hero-schedule { max-width:1020px; margin:0 auto 34px; display:grid; grid-template-columns:1fr 365px; gap:34px 70px; align-items:center; text-align:left; position:relative; }
.hero-schedule__intro { padding-left:4px; }
.hero-kicker { display:inline-flex; align-items:center; gap:8px; color:#ffe7b0; font-size:.76rem; font-weight:800; letter-spacing:1.4px; text-transform:uppercase; margin-bottom:14px; }
.hero h1 { font-size:clamp(2.5rem, 5vw, 4.6rem); line-height:.98; font-weight:800; margin-bottom:18px; letter-spacing:0; }
.hero h1 em { color:#ffd477; font-style:normal; }
.hero p { font-size:1.05rem; opacity:.9; max-width:540px; margin:0; }
.hero-date-stamp { display:flex; align-items:center; gap:12px; margin-top:28px; color:#fff; }
.hero-date-stamp strong { font-size:3.8rem; line-height:.8; color:#ffd477; }
.hero-date-stamp span { border-left:1px solid rgba(255,255,255,.45); padding-left:12px; font-size:.85rem; line-height:1.25; text-transform:uppercase; letter-spacing:1px; }
.hero-date-stamp b { font-size:1.1rem; }.hero-date-stamp small { opacity:.75; letter-spacing:0; text-transform:none; }
.hero-countdown { background:#161616; border:1px solid rgba(255,255,255,.25); border-radius:var(--radius-lg); padding:24px 20px 20px; text-align:center; box-shadow:12px 14px 0 rgba(255,212,119,.22); }
.hero-countdown__label { display:block; font-size:.72rem; text-transform:uppercase; letter-spacing:1.5px; color:#ffd477; }
.hero-countdown__digits { display:grid; grid-template-columns:repeat(4,1fr); gap:6px; margin:17px 0 13px; }
.hero-countdown__digits span { padding:10px 4px; background:#292929; border:1px solid #414141; border-radius:5px; }
.hero-countdown__digits b { display:block; font-size:1.55rem; line-height:1; letter-spacing:1px; }
.hero-countdown__digits small { display:block; margin-top:5px; color:#b9b9b9; font-size:.65rem; text-transform:uppercase; }
.hero-countdown small { display:block; opacity:.78; font-size:.78rem; }
.hero-timeline { grid-column:1 / -1; display:flex; align-items:center; gap:14px; }
.hero-date { min-width:145px; display:flex; flex-direction:column; gap:2px; }
.hero-date--end { text-align:right; }
.hero-date span { color:#ffe7b0; font-size:.7rem; font-weight:800; letter-spacing:1px; text-transform:uppercase; }
.hero-date strong { font-size:1.05rem; }
.hero-date small { font-size:.78rem; opacity:.78; }
.hero-timeline__track { flex:1; height:4px; background:rgba(255,255,255,.35); position:relative; border-radius:99px; }
.hero-timeline__track:before,.hero-timeline__track:after { content:""; position:absolute; top:50%; width:12px; height:12px; transform:translateY(-50%); border:3px solid #fff; background:var(--secondary); border-radius:50%; }
.hero-timeline__track:before { left:0; }.hero-timeline__track:after { right:0; }

.hero .search-box {
    max-width: 500px; margin: 0 auto; display: flex; gap: 8px;
}

.hero .search-box input {
    flex: 1; padding: 14px 20px; border: none; border-radius: var(--radius);
    font-size: 1rem; font-family: inherit;
}

.hero .search-box button {
    padding: 14px 24px; background: var(--dark); color: var(--white);
    border: none; border-radius: var(--radius); cursor: pointer; font-weight: 600;
    font-family: inherit; transition: var(--transition);
}

.hero .search-box button:hover { background: var(--gray-800); }

/* =============================================
   AUTH PAGE (candidate login)
   ============================================= */
.auth-page {
    position: relative;
    padding: 68px 0;
    overflow: hidden;
}

.auth-page__bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(circle at top left, rgba(204, 0, 0, 0.14), transparent 34%),
        radial-gradient(circle at bottom right, rgba(245, 166, 35, 0.18), transparent 36%),
        linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    pointer-events: none;
}

.auth-page__container {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(340px, 440px);
    gap: 28px;
    align-items: center;
}

.auth-hero {
    padding: 24px 10px;
}

.auth-hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 7px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,0.8);
    color: var(--primary);
    border: 1px solid rgba(204,0,0,0.14);
    font-size: 0.82rem;
    font-weight: 700;
    margin-bottom: 16px;
    box-shadow: var(--shadow);
}

.auth-hero h1 {
    font-size: clamp(2rem, 4vw, 3.35rem);
    line-height: 1.05;
    color: #0f172a;
    max-width: 14ch;
    margin-bottom: 16px;
}

.auth-hero p {
    max-width: 58ch;
    color: var(--gray-600);
    font-size: 1.02rem;
    line-height: 1.7;
}

.auth-hero__steps {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 22px;
}

.auth-hero__steps span {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,0.8);
    border: 1px solid rgba(148, 163, 184, 0.28);
    color: #334155;
    font-size: 0.85rem;
    font-weight: 600;
    box-shadow: var(--shadow);
}

.auth-hero__steps i { color: var(--success); }

.auth-card--candidate {
    position: relative;
    border: 1px solid rgba(204, 0, 0, 0.12);
    box-shadow: 0 24px 48px rgba(15, 23, 42, 0.12);
    overflow: hidden;
}

.auth-card--candidate::before {
    content: '';
    position: absolute;
    inset: 0 auto auto 0;
    width: 100%;
    height: 6px;
    background: linear-gradient(90deg, var(--primary) 0%, var(--secondary) 100%);
}

.auth-card__body {
    padding: 42px;
}

.auth-card__header {
    margin-bottom: 18px;
}

.auth-card__header h2 {
    font-size: 1.55rem;
    color: #0f172a;
    margin-bottom: 6px;
}

.auth-card__header p {
    color: var(--gray-500);
}

.auth-note {
    margin-bottom: 18px;
    font-size: 0.94rem;
    border-left: 4px solid var(--info);
}

.auth-form .form-group { margin-bottom: 16px; }

.auth-form .form-control {
    background: #fff;
    border: 1px solid #d7dde6;
    border-radius: 10px;
    padding: 14px 16px;
    transition: var(--transition);
}

.auth-form .form-control:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(204, 0, 0, 0.12);
}

.auth-submit {
    margin-top: 6px;
    padding-top: 14px;
    padding-bottom: 14px;
    box-shadow: 0 14px 24px rgba(204, 0, 0, 0.18);
}

.auth-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 18px;
    font-size: 0.92rem;
}

.auth-links a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--gray-600);
}

.auth-links a:hover { color: var(--primary); }

/* =============================================
   SECTIONS
   ============================================= */
.section { padding: 60px 0; }
.section-alt { background: var(--white); }
.section-title { font-size: 1.8rem; font-weight: 700; text-align: center; margin-bottom: 12px; color: var(--dark); }
.section-subtitle { text-align: center; color: var(--gray-500); margin-bottom: 40px; font-size: 1rem; }

/* =============================================
   CONCURSO CARDS
   ============================================= */
.concursos-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(350px, 1fr)); gap: 24px; }

.concurso-card {
    background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow);
    overflow: hidden; transition: var(--transition); border: 1px solid var(--gray-200);
}

.concurso-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }

.concurso-card-img {
    width: 100%; height: 180px; object-fit: cover; background: var(--primary-light);
    display: flex; align-items: center; justify-content: center;
}

.concurso-card-img i { font-size: 3rem; color: var(--primary); }

.concurso-card-body { padding: 20px; }

.concurso-card-body h3 { font-size: 1.1rem; font-weight: 700; margin-bottom: 8px; color: var(--dark); }
.concurso-card-body h3 a { color: var(--dark); }
.concurso-card-body h3 a:hover { color: var(--primary); }

.concurso-card-body p { color: var(--gray-500); font-size: 0.9rem; margin-bottom: 16px; display: -webkit-box; line-clamp: 2; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.concurso-meta { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; font-size: 0.85rem; color: var(--gray-500); }
.concurso-meta span { display: flex; align-items: center; gap: 4px; }
.concurso-meta i { color: var(--primary); }

.concurso-card-footer {
    padding: 16px 20px; border-top: 1px solid var(--gray-200);
    display: flex; justify-content: space-between; align-items: center;
}

/* =============================================
   BUTTONS
   ============================================= */
.btn {
    display: inline-flex; align-items: center; gap: 8px; padding: 10px 24px;
    border: none; border-radius: var(--radius); font-size: 0.9rem; font-weight: 600;
    cursor: pointer; transition: var(--transition); text-decoration: none;
    font-family: inherit; white-space: nowrap; justify-content: center;
}

.btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-md); }

.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dark); color: var(--white); }

.btn-success { background: var(--success); color: var(--white); }
.btn-success:hover { background: #0c875e; color: var(--white); }

.btn-warning { background: var(--warning); color: var(--white); }
.btn-danger { background: var(--danger); color: var(--white); }
.btn-info { background: var(--info); color: var(--white); }
.btn-secondary { background: var(--gray-500); color: var(--white); }

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

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

.btn-sm { padding: 6px 14px; font-size: 0.8rem; }
.btn-lg { padding: 14px 32px; font-size: 1rem; }
.btn-group { display: flex; gap: 8px; flex-wrap: wrap; }

/* =============================================
   BADGE
   ============================================= */
.badge {
    display: inline-flex; align-items: center; padding: 4px 12px; border-radius: 20px;
    font-size: 0.75rem; font-weight: 600;
}
.badge-primary { background: var(--primary-light); color: var(--primary); }
.badge-success { background: #d1fae5; color: var(--success); }
.badge-warning { background: #fef3c7; color: #92400e; }
.badge-danger { background: #fee2e2; color: var(--danger); }
.badge-info { background: #dbeafe; color: #1e40af; }
.badge-secondary { background: var(--gray-200); color: var(--gray-600); }

/* =============================================
   ALERTS
   ============================================= */
.alert {
    display: flex; align-items: center; justify-content: space-between; padding: 14px 18px;
    border-radius: var(--radius); margin-bottom: 20px; font-size: 0.9rem;
}
.alert-success { background: #d1fae5; color: #065f46; }
.alert-danger { background: #fee2e2; color: #991b1b; }
.alert-warning { background: #fef3c7; color: #92400e; }
.alert-info { background: #dbeafe; color: #1e40af; }
.alert-close { background: none; border: none; font-size: 1.2rem; cursor: pointer; color: inherit; opacity: 0.6; }
.alert-close:hover { opacity: 1; }

/* =============================================
   REQUERIMENTOS DESTACADOS
   ============================================= */
.requirement-highlight {
    border-radius: 16px;
    padding: 18px 20px;
    margin-bottom: 14px;
    box-shadow: var(--shadow-md);
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255,255,255,0.35);
}

.requirement-highlight::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 7px;
    background: linear-gradient(180deg, var(--primary) 0%, var(--secondary) 100%);
}

.requirement-highlight--main {
    background: linear-gradient(135deg, #fff2f2 0%, #ffe8e8 100%);
}

.requirement-highlight--secondary {
    background: linear-gradient(135deg, #fdf7e8 0%, #fff3d5 100%);
}

.requirement-highlight h4 {
    margin: 0 0 8px;
    color: var(--primary-dark);
    font-size: 1.03rem;
    font-weight: 800;
}

.requirement-highlight p {
    margin: 0;
    color: var(--gray-700);
    font-size: 0.95rem;
    line-height: 1.75;
}

.requirement-highlight .requirement-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
    padding: 6px 12px;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--primary) 0%, var(--secondary) 100%);
    color: var(--white);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}

.requirement-card {
    border: 1px solid var(--gray-200);
    border-radius: 14px;
    padding: 16px;
    margin-top: 12px;
    background: linear-gradient(135deg, #ffffff 0%, #fdf2f2 100%);
    box-shadow: var(--shadow);
}

.requirement-card__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.requirement-card__header h4 {
    margin: 0 0 4px;
    color: var(--primary-dark);
    font-size: 1rem;
    font-weight: 700;
}

.requirement-card__header p {
    margin: 0;
    color: var(--gray-500);
    font-size: 0.92rem;
}

.requirement-card__body {
    margin-top: 12px;
    padding: 12px;
    border-radius: 10px;
    background: var(--white);
    border: 1px solid var(--gray-200);
    line-height: 1.75;
    color: var(--gray-700);
}

/* =============================================
   FORMS
   ============================================= */
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-weight: 600; margin-bottom: 6px; color: var(--gray-700); font-size: 0.9rem; }

.form-control {
    width: 100%; padding: 12px 16px; border: 1px solid var(--gray-300);
    border-radius: var(--radius); font-size: 0.95rem; color: var(--dark);
    transition: var(--transition); background: var(--white); font-family: inherit;
}

.form-control:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(26,86,219,0.15); }

select.form-control { cursor: pointer; }
textarea.form-control { resize: vertical; min-height: 120px; }

.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.form-text { font-size: 0.8rem; color: var(--gray-500); margin-top: 4px; }

.form-check { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.form-check input { width: 18px; height: 18px; accent-color: var(--primary); }

/* =============================================
   CARD (Generic)
   ============================================= */
.card {
    background: var(--white); border-radius: var(--radius-lg);
    box-shadow: var(--shadow); border: 1px solid var(--gray-200); overflow: hidden;
}

.card-header { padding: 16px 20px; border-bottom: 1px solid var(--gray-200); }
.card-header h3 { font-size: 1.1rem; font-weight: 600; }
.card-body { padding: 20px; }
.card-footer { padding: 16px 20px; border-top: 1px solid var(--gray-200); background: var(--gray-100); }

/* =============================================
   TABLES
   ============================================= */
.table-responsive { overflow-x: auto; }

table { width: 100%; border-collapse: collapse; }
table th, table td { padding: 12px 16px; text-align: left; border-bottom: 1px solid var(--gray-200); font-size: 0.9rem; }
table th { background: var(--gray-100); font-weight: 600; color: var(--gray-600); text-transform: uppercase; font-size: 0.75rem; letter-spacing: 0.5px; }
table tbody tr { transition: var(--transition); }
table tbody tr:hover { background: var(--gray-100); }

/* =============================================
   PAGINATION
   ============================================= */
.paginacao { margin-top: 24px; }
.paginacao ul { display: flex; gap: 4px; list-style: none; justify-content: center; }
.paginacao li a {
    display: flex; align-items: center; justify-content: center;
    min-width: 36px; height: 36px; padding: 0 10px; border-radius: var(--radius);
    border: 1px solid var(--gray-300); color: var(--gray-600); font-size: 0.85rem;
    transition: var(--transition);
}
.paginacao li a:hover { background: var(--primary-light); color: var(--primary); border-color: var(--primary); }
.paginacao li.ativo a { background: var(--primary); color: var(--white); border-color: var(--primary); }

/* =============================================
   CANDIDATE DASHBOARD
   ============================================= */
.dashboard-grid { display: grid; grid-template-columns: 250px 1fr; gap: 24px; min-height: 600px; }

.dash-sidebar {
    background:
        radial-gradient(circle at top right, rgba(245,166,35,0.14), transparent 48%),
        linear-gradient(180deg, #ffffff 0%, #f8fbff 100%);
    border-radius: 16px;
    box-shadow: 0 16px 34px rgba(15, 23, 42, 0.08);
    padding: 20px;
    border: 1px solid #dbe5f0;
    height: fit-content;
    position: sticky;
    top: 90px;
}

.dash-user-info {
    text-align: center;
    padding-bottom: 16px;
    border-bottom: 1px solid #dbe5f0;
    margin-bottom: 16px;
}
.dash-user-info .avatar {
    width: 82px;
    height: 82px;
    border-radius: 50%;
    background: linear-gradient(140deg, #ffe1cf 0%, #ffd4d4 60%, #ffffff 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 12px;
    font-size: 2rem;
    color: #b91c1c;
    border: 2px solid rgba(255, 255, 255, 0.95);
    box-shadow: 0 8px 18px rgba(185, 28, 28, 0.16);
}
.dash-user-info h3 {
    font-size: 1rem;
    font-weight: 700;
    color: #0f172a;
}
.dash-user-info p {
    font-size: 0.84rem;
    color: #64748b;
}

.dash-nav a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 14px;
    color: #334155;
    border-radius: 10px;
    font-size: 0.9rem;
    transition: var(--transition);
    margin-bottom: 4px;
    font-weight: 600;
}
.dash-nav a:hover {
    background: #fef3f2;
    color: #b91c1c;
}
.dash-nav a.active {
    background: linear-gradient(120deg, #cc0000 0%, #a30000 100%);
    color: var(--white);
    box-shadow: 0 10px 18px rgba(163, 0, 0, 0.28);
}
.dash-nav a i { width: 18px; text-align: center; }
.logout-nav-btn { display: block; width: 100%; margin-top: 8px; padding: 11px 14px; border: 1px solid transparent; border-radius: 6px; background: transparent; color: #b91c1c; font: inherit; font-weight: 700; text-align: left; cursor: pointer; transition: background-color .2s ease, color .2s ease, border-color .2s ease; }
.logout-nav-btn i { width: 18px; text-align: center; }
.logout-nav-btn:hover { background: #fef2f2; border-color: #fecaca; color: #991b1b; }

.dash-content { min-width: 0; }

.cand-page-hero {
    background:
        radial-gradient(circle at right top, rgba(245,166,35,0.26), transparent 38%),
        linear-gradient(125deg, #fff5f0 0%, #ffffff 45%, #f5f9ff 100%);
    border: 1px solid #f2d9cd;
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
}

.cand-page-hero h2 {
    margin: 0 0 6px;
    color: #0f172a;
    font-size: clamp(1.2rem, 2vw, 1.65rem);
}

.cand-page-hero p {
    margin: 0;
    color: #64748b;
    font-size: 0.95rem;
}

.cand-stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 14px;
    margin-bottom: 24px;
}

.cand-stat-card {
    position: relative;
    border-radius: 14px;
    padding: 18px;
    border: 1px solid #dbe5f0;
    background: linear-gradient(160deg, #ffffff 0%, #f8fbff 100%);
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.cand-stat-card::after {
    content: '';
    position: absolute;
    right: -10px;
    bottom: -10px;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(14, 165, 233, 0.08);
    pointer-events: none;
}

.cand-stat-card__kpi {
    font-size: 1.9rem;
    line-height: 1;
    font-weight: 800;
    color: #0f172a;
    margin-bottom: 8px;
}

.cand-stat-card__label {
    color: #64748b;
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-weight: 700;
}

.cand-stat-card--primary .cand-stat-card__kpi { color: #b91c1c; }
.cand-stat-card--success .cand-stat-card__kpi { color: #047857; }
.cand-stat-card--info .cand-stat-card__kpi { color: #1d4ed8; }
.cand-stat-card--accent .cand-stat-card__kpi { color: #b45309; }

.cand-card {
    border-radius: 16px;
    border: 1px solid #dce6f2;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.cand-card .card-header {
    background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.cand-card .card-header h3 {
    margin: 0;
    color: #0f172a;
}

.cand-inscricao-card {
    border-radius: 14px;
    border: 1px solid #dbe5f0;
    box-shadow: 0 10px 24px rgba(15, 23, 42, 0.07);
}

.cand-inscricao-card__head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 12px;
}

.cand-inscricao-card h3 {
    margin-bottom: 4px;
    font-size: 1.04rem;
}

.cand-inscricao-card__meta {
    color: var(--gray-500);
    font-size: 0.9rem;
}

.cand-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
    gap: 10px;
    margin-top: 14px;
}

.cand-info-grid .info-item {
    background: linear-gradient(180deg, #fbfdff 0%, #f3f7fc 100%);
    border: 1px solid #e1e8f2;
}

.cand-actions {
    margin-top: 14px;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.cand-chat-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 16px;
    align-items: start;
}

.cand-chat-card {
    border-radius: 16px;
    border: 1px solid #dce6f2;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.08);
}

.cand-chat-shell {
    display: flex;
    flex-direction: column;
    min-height: 540px;
}

.cand-chat-messages {
    flex: 1;
    height: 460px;
    overflow-y: auto;
    padding: 16px;
    background: linear-gradient(180deg, #f8fbff 0%, #f4f8ff 100%);
    border-bottom: 1px solid #e2e8f0;
}

.cand-chat-row {
    display: flex;
    margin-bottom: 10px;
}

.cand-chat-row--mine {
    justify-content: flex-end;
}

.cand-chat-row--other {
    justify-content: flex-start;
}

.cand-chat-bubble {
    max-width: 78%;
    border-radius: 12px;
    padding: 10px 12px;
    border: 1px solid #d1d5db;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.06);
}

.cand-chat-bubble--mine {
    background: #dbeafe;
}

.cand-chat-bubble--other {
    background: #ffffff;
}

.cand-chat-meta {
    font-size: 0.75rem;
    color: #64748b;
    margin-bottom: 4px;
}

.cand-chat-text {
    white-space: pre-wrap;
}

.cand-chat-form {
    padding: 12px;
    display: flex;
    gap: 8px;
    align-items: flex-end;
}

.cand-chat-form textarea {
    min-height: 58px;
}

.cand-online-list {
    display: grid;
    gap: 8px;
}

.cand-online-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 10px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
}

.cand-online-dot {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background: #22c55e;
    display: inline-block;
}

/* =============================================
   DETAIL PAGE
   ============================================= */
.detail-header { margin-bottom: 24px; }
.detail-header h1 { font-size: 1.8rem; font-weight: 700; margin-bottom: 8px; }

.detail-info-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; margin-bottom: 24px; }

.info-item { padding: 16px; background: var(--gray-100); border-radius: var(--radius); }
.info-item label { font-size: 0.8rem; color: var(--gray-500); text-transform: uppercase; letter-spacing: 0.5px; display: block; margin-bottom: 4px; }
.info-item span { font-weight: 600; color: var(--dark); font-size: 1rem; }

/* =============================================
   AUTH PAGES
   ============================================= */
.auth-wrapper {
    min-height: 100vh; display: flex; align-items: center; justify-content: center;
    background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
    padding: 20px;
}

.auth-card {
    background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg);
    width: 100%; max-width: 480px; padding: 40px;
}

.auth-card h1 { text-align: center; font-size: 1.5rem; margin-bottom: 8px; }
.auth-card .subtitle { text-align: center; color: var(--gray-500); margin-bottom: 24px; font-size: 0.9rem; }

/* =============================================
   EXAM PAGE
   ============================================= */
.exam-wrapper { max-width: 900px; margin: 0 auto; padding: 24px 20px; }

.exam-header {
    background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow);
    padding: 20px; margin-bottom: 24px; display: flex; justify-content: space-between;
    align-items: center; position: sticky; top: 80px; z-index: 100;
}

.exam-timer {
    font-size: 1.5rem; font-weight: 700; color: var(--primary);
    display: flex; align-items: center; gap: 8px;
}

.exam-timer.warning { color: var(--warning); }
.exam-timer.danger { color: var(--danger); animation: pulse 1s infinite; }

@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

.exam-progress { display: flex; align-items: center; gap: 12px; }
.progress-bar { width: 200px; height: 8px; background: var(--gray-200); border-radius: 4px; overflow: hidden; }
.progress-bar-fill { height: 100%; background: var(--primary); border-radius: 4px; transition: var(--transition); }
.progress-text { font-size: 0.85rem; color: var(--gray-500); font-weight: 600; }

.question-card {
    background: var(--white); border-radius: var(--radius-lg); box-shadow: var(--shadow);
    padding: 24px; margin-bottom: 20px; border: 1px solid var(--gray-200);
}

.question-number { font-size: 0.85rem; color: var(--primary); font-weight: 700; margin-bottom: 12px; text-transform: uppercase; letter-spacing: 0.5px; }
.question-text { font-size: 1rem; line-height: 1.7; margin-bottom: 20px; color: var(--dark); }
.question-image { max-width: 100%; border-radius: var(--radius); margin-bottom: 16px; }

.alternatives-list { list-style: none; display: flex; flex-direction: column; gap: 8px; }

.alternative-item {
    display: flex; align-items: flex-start; gap: 12px; padding: 14px 16px;
    border: 2px solid var(--gray-200); border-radius: var(--radius);
    cursor: pointer; transition: var(--transition);
}

.alternative-item:hover { border-color: var(--primary); background: var(--primary-light); }
.alternative-item.selected { border-color: var(--primary); background: var(--primary-light); }

.alternative-item input[type="radio"] { margin-top: 3px; accent-color: var(--primary); }
.alternative-item label { cursor: pointer; line-height: 1.5; flex: 1; }

.question-nav {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(40px, 1fr)); gap: 8px;
    margin-bottom: 24px;
}

.question-nav-btn {
    width: 40px; height: 40px; border: 1px solid var(--gray-300); border-radius: var(--radius);
    display: flex; align-items: center; justify-content: center; font-size: 0.85rem;
    cursor: pointer; transition: var(--transition); background: var(--white); font-weight: 600;
}
.question-nav-btn:hover { border-color: var(--primary); }
.question-nav-btn.answered { background: var(--primary); color: var(--white); border-color: var(--primary); }
.question-nav-btn.current { border-color: var(--warning); border-width: 2px; }

/* =============================================
   FOOTER
   ============================================= */
.site-footer { background: var(--dark); color: var(--gray-400); padding: 40px 0 20px; }

.site-footer {
    background:
        linear-gradient(180deg, #1a1a1a 0%, #0a0a0a 100%),
        repeating-linear-gradient(135deg, rgba(255,255,255,0.03) 0, rgba(255,255,255,0.03) 8px, transparent 8px, transparent 16px);
    color: #b8c2cf;
    border-top: 4px solid var(--secondary);
}

.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 32px; margin-bottom: 32px; }

.footer-col h4 {
    color: #f3f6fa;
    font-size: 0.95rem;
    margin-bottom: 14px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.footer-col p { font-size: 0.9rem; line-height: 1.7; }

.footer-col a {
    color: #c7d0db;
    font-size: 0.9rem;
    display: block;
    padding: 4px 0;
    transition: var(--transition);
}

.footer-col a:hover { color: var(--white); }

.footer-bottom {
    border-top: 1px solid rgba(255,255,255,0.12); padding-top: 20px;
    text-align: center; font-size: 0.85rem;
}

/* =============================================
   STATS (public page)
   ============================================= */
.stats-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 20px; margin-bottom: 40px; }

.stat-box { text-align: center; padding: 24px 16px; }
.stat-box .stat-number { font-size: 2.2rem; font-weight: 800; color: var(--primary); }
.stat-box .stat-label { font-size: 0.9rem; color: var(--gray-500); margin-top: 4px; }

/* =============================================
   EMPTY STATE
   ============================================= */
.empty-state { text-align: center; padding: 60px 20px; color: var(--gray-500); }
.empty-state i { font-size: 3rem; margin-bottom: 16px; color: var(--gray-300); }
.empty-state h3 { font-size: 1.2rem; color: var(--gray-600); margin-bottom: 8px; }

/* =============================================
   VAGAS AGRUPADAS (public page)
   ============================================= */
.vaga-hierarchy {
    display: grid;
    gap: 18px;
}

.vaga-municipio-card {
    background: linear-gradient(180deg, #ffffff 0%, #fff8f6 100%);
    border: 1px solid #f4dfd8;
    border-radius: 14px;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.04);
    overflow: hidden;
}

.vaga-municipio-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 14px 18px;
    background: linear-gradient(90deg, rgba(204, 0, 0, 0.08) 0%, rgba(245, 166, 35, 0.12) 100%);
    border-bottom: 1px solid #f1ddd7;
}

.vaga-municipio-header h3 {
    margin: 0;
    font-size: 1.02rem;
    color: #7f1d1d;
    font-weight: 800;
    display: flex;
    align-items: center;
    gap: 8px;
}

.vaga-municipio-header h3 i {
    color: var(--primary);
}

.vaga-total-pill {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 104px;
    padding: 6px 10px;
    border-radius: 999px;
    background: #ffffff;
    border: 1px solid #efc0b3;
    color: #8a2f1a;
    font-weight: 700;
    font-size: 0.85rem;
}

.vaga-categorias-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 12px;
    padding: 14px;
}

.vaga-categoria-card {
    border: 1px solid #eceff3;
    background: #ffffff;
    border-radius: 12px;
    padding: 12px;
}

.vaga-categoria-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-bottom: 8px;
    padding-bottom: 7px;
    border-bottom: 1px dashed #d5dde7;
}

.vaga-categoria-header h4 {
    margin: 0;
    font-size: 0.92rem;
    color: #1f2937;
    font-weight: 700;
}

.vaga-categoria-total {
    min-width: 34px;
    text-align: center;
    background: #f0f6ff;
    color: #1f4b87;
    border: 1px solid #d3e4fb;
    border-radius: 7px;
    font-size: 0.8rem;
    font-weight: 700;
    padding: 3px 7px;
}

.vaga-especialidades-list {
    list-style: none;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 6px;
}

.vaga-especialidades-list li {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    border: 1px solid #eff3f7;
    border-radius: 9px;
    padding: 8px 10px;
    background: #fcfdff;
}

.vaga-especialidade-nome {
    font-size: 0.88rem;
    color: #334155;
    line-height: 1.3;
}

.vaga-especialidade-pill {
    flex-shrink: 0;
    background: #fff2e8;
    color: #9a3412;
    border: 1px solid #fed7aa;
    border-radius: 999px;
    padding: 3px 8px;
    font-size: 0.74rem;
    font-weight: 700;
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 768px) {
    .hero h1 { font-size: 1.8rem; }
    .hero { padding: 50px 0; }
    .hero-schedule { display:block; text-align:center; }
    .hero-schedule__intro { padding:0; }
    .hero-countdown { max-width:320px; margin:24px auto; }
    .hero-date-stamp { justify-content:center; text-align:left; }
    .hero-timeline { gap:8px; text-align:left; }
    .hero-date { min-width:98px; }.hero-date--end { text-align:right; }
    .hero-date strong { font-size:.9rem; }.hero-date small { font-size:.72rem; }
    .hero-countdown__digits b { font-size:1.2rem; }
    .hero .search-box { flex-direction: column; }
    .concursos-grid { grid-template-columns: 1fr; }
    .dashboard-grid { grid-template-columns: 1fr; }
    .dash-sidebar { position: static; }
    .gov-strip-inner { min-height: 30px; font-size: 0.72rem; }
    .gov-strip-links { display: none; }
    .main-nav { display: none; position: absolute; top: 108px; left: 0; right: 0; background: var(--white); flex-direction: column; padding: 16px; box-shadow: var(--shadow-md); }
    .main-nav.active { display: flex; }
    .mobile-toggle { display: block; }
    .exam-header { flex-direction: column; gap: 12px; align-items: flex-start; }
    .header-inner { height: auto; padding: 12px 20px; flex-wrap: wrap; }
    .logo-text small { display: none; }
    .logo-text strong { font-size: 0.9rem; }
    .section { padding: 40px 0; }
    .section-title { font-size: 1.4rem; }
    .auth-page { padding: 38px 0; }
    .auth-page__container { grid-template-columns: 1fr; }
    .auth-hero { padding: 8px 0 0; }
    .auth-hero h1 { max-width: none; }
    .auth-card__body { padding: 26px; }
    .cand-page-hero { padding: 16px; }
    .cand-stat-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .cand-chat-layout { grid-template-columns: 1fr; }
    .cand-chat-messages { height: 400px; }
    .vaga-municipio-header {
        flex-direction: column;
        align-items: flex-start;
    }
    .vaga-total-pill {
        min-width: 0;
    }
    .vaga-categorias-grid {
        grid-template-columns: 1fr;
        padding: 12px;
    }
}

@media (max-width: 480px) {
    .container { padding: 0 16px; }
    .auth-card { padding: 24px; }
    .auth-hero__steps { flex-direction: column; align-items: flex-start; }
    .cand-stat-grid { grid-template-columns: 1fr; }
}

/* Utility classes */
.w-100 { width: 100%; }
.mb-3 { margin-bottom: 24px; }
.mb-2 { margin-bottom: 16px; }
.mb-1 { margin-bottom: 8px; }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.text-center { text-align: center; }
.text-success { color: var(--success); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.d-flex { display: flex; }
.gap-1 { gap: 8px; }
.gap-2 { gap: 16px; }
.img-preview { max-width: 200px; max-height: 200px; object-fit: contain; border-radius: var(--radius); border: 1px solid var(--gray-200); }
