/* ============================================================
   FESTIVAL DIGITAL — Design System
   Paleta extraída da logo oficial
   ============================================================ */
:root {
    --purple:        #7B2FF7;
    --purple-dark:   #5A1FCC;
    --purple-light:  #9B5FFF;
    --pink:          #D946EF;
    --cyan:          #00C6FB;
    --blue:          #2D9CDB;
    --navy:          #1A0A3D;

    --gradient:         linear-gradient(135deg, var(--purple) 0%, var(--pink) 50%, var(--blue) 100%);
    --gradient-h:       linear-gradient(90deg,  var(--purple) 0%, var(--pink) 100%);
    --gradient-cyan:    linear-gradient(135deg, var(--cyan) 0%, var(--blue) 100%);
    --gradient-subtle:  linear-gradient(135deg, rgba(123,47,247,.08) 0%, rgba(0,198,251,.08) 100%);

    --text-dark:     #1A0A3D;
    --text-body:     #374151;
    --text-muted:    #6B7280;
    --text-light:    #9CA3AF;

    --bg-page:       #F3F4F8;
    --bg-white:      #FFFFFF;
    --bg-subtle:     #F8F7FF;

    --border:        #E5E7EB;
    --border-focus:  rgba(123, 47, 247, 0.4);

    --shadow-sm:     0 1px 3px rgba(0,0,0,.08);
    --shadow-md:     0 4px 16px rgba(0,0,0,.10);
    --shadow-lg:     0 12px 40px rgba(0,0,0,.13);
    --shadow-purple: 0 8px 24px rgba(123,47,247,.25);
    --shadow-glow:   0 0 0 3px rgba(123,47,247,.15);

    --radius-sm:     8px;
    --radius-md:     14px;
    --radius-lg:     20px;
    --radius-xl:     28px;

    --transition:    all 0.22s cubic-bezier(.4,0,.2,1);

    /* Semantic surface tokens (overridden no tema escuro) */
    --footer-bg:     var(--navy);
    --link-color:    var(--purple);
    --code-bg:       #F1F5F9;
    --theme-toggle-bg:     rgba(123,47,247,.08);
    --theme-toggle-color:  var(--purple);
}

/* ============================================================
   DARK THEME — sobrescreve apenas tokens semânticos
   (as cores de marca: purple/pink/cyan/blue permanecem)
   ============================================================ */
[data-theme="dark"] {
    --text-dark:     #F4F1FF;
    --text-body:     #C7C1DA;
    --text-muted:    #968FAE;
    --text-light:    #6F6889;

    --bg-page:       #0E0A1C;
    --bg-white:      #181227;
    --bg-subtle:     #211934;

    --border:        #2C2542;
    --border-focus:  rgba(155, 95, 255, 0.55);

    --shadow-sm:     0 1px 3px rgba(0,0,0,.45);
    --shadow-md:     0 4px 16px rgba(0,0,0,.55);
    --shadow-lg:     0 12px 40px rgba(0,0,0,.65);
    --shadow-purple: 0 8px 24px rgba(123,47,247,.45);
    --shadow-glow:   0 0 0 3px rgba(155,95,255,.25);

    --gradient-subtle: linear-gradient(135deg, rgba(123,47,247,.18) 0%, rgba(0,198,251,.12) 100%);

    --footer-bg:     #0A0617;
    --link-color:    var(--purple-light);
    --code-bg:       #211934;
    --theme-toggle-bg:    rgba(155,95,255,.16);
    --theme-toggle-color: var(--purple-light);

    color-scheme: dark;
}

/* Transições suaves ao trocar de tema */
body,
.navbar-custom,
.card-custom, .card-festival, .card-stat, .card-feature,
.form-control, .form-select,
.table-custom thead th,
.footer-custom,
.auth-card {
    transition: background-color .3s ease, border-color .3s ease, color .3s ease, box-shadow .3s ease;
}

/* ── Botão de troca de tema (sol/lua) ─────────────────────── */
.theme-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border: 1px solid var(--border);
    background: var(--theme-toggle-bg);
    color: var(--theme-toggle-color);
    border-radius: var(--radius-sm);
    font-size: 1.05rem;
    cursor: pointer;
    transition: var(--transition);
    padding: 0;
    line-height: 1;
}
.theme-toggle:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-sm);
    border-color: var(--border-focus);
}
/* Apenas um ícone visível por vez, com cor própria */
.theme-toggle .theme-icon-sun,
.theme-toggle .theme-icon-moon {
    transition: transform .25s ease, opacity .2s ease;
}
.theme-toggle .theme-icon-sun  { display: none; color: #FBBF24; }   /* sol amarelo */
.theme-toggle .theme-icon-moon { display: inline-block; color: #93C5FD; } /* lua azul-clara */
[data-theme="dark"] .theme-toggle {
    background: rgba(147,197,253,.14);
    border-color: rgba(147,197,253,.3);
}
[data-theme="dark"] .theme-toggle .theme-icon-sun  { display: inline-block; }
[data-theme="dark"] .theme-toggle .theme-icon-moon { display: none; }
.theme-toggle:hover .theme-icon-sun,
.theme-toggle:hover .theme-icon-moon { transform: rotate(-12deg) scale(1.12); }

/* ── Base ─────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

body {
    background-color: var(--bg-page);
    color: var(--text-body);
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    font-size: 15px;
    line-height: 1.6;
    margin: 0; padding: 0;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, h5, h6 { color: var(--text-dark); font-weight: 700; line-height: 1.25; }
a { color: var(--link-color); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--purple-light); }

/* ── Typography helpers ───────────────────────────────────── */
.text-gradient {
    background: var(--gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    display: inline-block;
}
.text-gradient-cyan {
    background: var(--gradient-cyan);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 700;
    display: inline-block;
}
.text-navy  { color: var(--navy) !important; }
.text-purple { color: var(--purple) !important; }

/* ── Backgrounds ─────────────────────────────────────────── */
.bg-gradient-custom  { background: var(--gradient); color: #fff; }
.bg-gradient-hero    { background: linear-gradient(145deg, var(--navy) 0%, #3D1688 55%, #1a2a5e 100%); }
.bg-gradient-subtle  { background: var(--gradient-subtle); }
.bg-purple-soft      { background: rgba(123,47,247,.08); }
.bg-page             { background-color: var(--bg-page); }

/* ── Navbar ───────────────────────────────────────────────── */
.navbar-custom {
    background-color: var(--bg-white);
    box-shadow: 0 1px 0 var(--border), var(--shadow-sm);
    position: sticky;
    top: 0;
    z-index: 1030;
    padding-top: .75rem;
    padding-bottom: .75rem;
}

.navbar-custom .navbar-brand img { transition: var(--transition); }
.navbar-custom .navbar-brand:hover img { transform: scale(1.04); }

.navbar-custom .nav-link {
    color: var(--text-body) !important;
    font-weight: 500;
    font-size: .9rem;
    padding: .45rem .75rem !important;
    border-radius: var(--radius-sm);
    position: relative;
    transition: var(--transition);
}
.navbar-custom .nav-link:hover {
    color: var(--purple) !important;
    background: var(--bg-subtle);
}
.navbar-custom .nav-link.active {
    color: var(--purple) !important;
    background: rgba(123,47,247,.08);
    font-weight: 600;
}
.navbar-custom .nav-link.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%; right: 50%;
    transform: translateX(-50%);
    width: 20px;
    height: 2px;
    background: var(--gradient);
    border-radius: 2px;
}

.navbar-custom .user-greeting {
    font-size: .85rem;
    font-weight: 600;
    color: var(--text-dark) !important;
    background: var(--bg-subtle);
    border: 1px solid var(--border);
    border-radius: 999px;
    padding: .35rem .9rem !important;
    display: flex;
    align-items: center;
    gap: .4rem;
}

.navbar-custom .btn-nav-logout {
    color: #EF4444 !important;
    font-weight: 500;
    font-size: .85rem;
    padding: .4rem .7rem !important;
    border-radius: var(--radius-sm);
}
.navbar-custom .btn-nav-logout:hover {
    background: #FEF2F2 !important;
    color: #DC2626 !important;
}

/* ── Buttons ─────────────────────────────────────────────── */
.btn-primary-custom {
    background: var(--gradient);
    border: none;
    color: #fff !important;
    font-weight: 600;
    font-size: .9rem;
    padding: .6rem 1.4rem;
    border-radius: var(--radius-sm);
    box-shadow: var(--shadow-purple);
    transition: var(--transition);
    letter-spacing: .01em;
}
.btn-primary-custom:hover, .btn-primary-custom:focus {
    transform: translateY(-2px);
    box-shadow: 0 10px 28px rgba(123,47,247,.35);
    color: #fff !important;
}
.btn-primary-custom:active { transform: translateY(0); }

.btn-outline-custom {
    background: transparent;
    border: 2px solid var(--purple);
    color: var(--purple) !important;
    font-weight: 600;
    font-size: .9rem;
    padding: .55rem 1.35rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.btn-outline-custom:hover {
    background: var(--purple);
    color: #fff !important;
    transform: translateY(-1px);
    box-shadow: var(--shadow-purple);
}

.btn-ghost {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: .85rem;
    font-weight: 500;
    padding: .45rem .8rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.btn-ghost:hover { background: var(--bg-subtle); color: var(--purple); }

.btn-danger-soft {
    background: #FEF2F2;
    border: 1px solid #FECACA;
    color: #DC2626;
    font-size: .85rem;
    font-weight: 500;
    padding: .4rem .9rem;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}
.btn-danger-soft:hover { background: #FEE2E2; color: #B91C1C; }

/* ── Cards ───────────────────────────────────────────────── */
.card-custom {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    background-color: var(--bg-white);
    transition: var(--transition);
}
.card-custom:hover { box-shadow: var(--shadow-md); }

.card-festival {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}
.card-festival:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(123,47,247,.25);
}

.card-stat {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    padding: 1.25rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    transition: var(--transition);
}
.card-stat:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }

.card-stat-icon {
    width: 52px; height: 52px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    flex-shrink: 0;
}
.stat-purple { background: rgba(123,47,247,.1); color: var(--purple); }
.stat-blue   { background: rgba(0,198,251,.12); color: var(--blue); }
.stat-pink   { background: rgba(217,70,239,.1); color: var(--pink); }
.stat-green  { background: rgba(16,185,129,.1); color: #059669; }

.card-stat-info .stat-value {
    font-size: 1.65rem;
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1;
    margin-bottom: .15rem;
}
.card-stat-info .stat-label {
    font-size: .8rem;
    color: var(--text-muted);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: .04em;
}

/* ── Feature card (landing) ──────────────────────────────── */
.card-feature {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    background: var(--bg-white);
    box-shadow: var(--shadow-sm);
    padding: 2rem 1.75rem;
    text-align: center;
    transition: var(--transition);
    position: relative;
    overflow: hidden;
}
.card-feature::before {
    content: '';
    position: absolute;
    inset: 0;
    background: var(--gradient-subtle);
    opacity: 0;
    transition: var(--transition);
}
.card-feature:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-lg);
    border-color: rgba(123,47,247,.3);
}
.card-feature:hover::before { opacity: 1; }

.feature-icon {
    width: 64px; height: 64px;
    background: var(--gradient);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.7rem;
    color: #fff;
    margin: 0 auto 1.25rem;
    position: relative;
    z-index: 1;
    box-shadow: var(--shadow-purple);
}

/* ── Forms ───────────────────────────────────────────────── */
.form-control, .form-select {
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    padding: .6rem .9rem;
    font-size: .9rem;
    color: var(--text-dark);
    background-color: var(--bg-white);
    transition: var(--transition);
}
.form-control:focus, .form-select:focus {
    border-color: var(--purple);
    box-shadow: var(--shadow-glow);
    outline: none;
}
.form-control::placeholder { color: var(--text-light); }
.form-label {
    font-size: .82rem;
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: .35rem;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.input-group-icon {
    position: relative;
}
.input-group-icon .form-control {
    padding-left: 2.5rem;
}
.input-group-icon .input-icon {
    position: absolute;
    left: .8rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1rem;
    z-index: 5;
    pointer-events: none;
}
.input-group-icon .input-icon-right {
    position: absolute;
    right: .8rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 1rem;
    z-index: 5;
    cursor: pointer;
}
.input-group-icon .input-icon-right:hover { color: var(--purple); }
.input-group-icon .form-control.with-right { padding-right: 2.5rem; }

.form-section-title {
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: var(--purple);
    display: flex;
    align-items: center;
    gap: .5rem;
    padding: .75rem 0 .5rem;
    border-bottom: 1px solid var(--border);
    margin-bottom: 1rem;
}

/* ── Badges ──────────────────────────────────────────────── */
.badge-custom {
    font-size: .72rem;
    font-weight: 600;
    padding: .3em .7em;
    border-radius: 999px;
    letter-spacing: .02em;
}
.badge-aberto    { background: #D1FAE5; color: #065F46; }
.badge-encerrado { background: #FEE2E2; color: #991B1B; }
.badge-pendente  { background: #FEF3C7; color: #92400E; }
.badge-pago      { background: #D1FAE5; color: #065F46; }
.badge-role      { background: rgba(123,47,247,.1); color: var(--purple); }

/* ── Tables ──────────────────────────────────────────────── */
.table-custom { width: 100%; border-collapse: separate; border-spacing: 0; }
.table-custom thead th {
    background: var(--bg-subtle);
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: var(--text-muted);
    padding: .75rem 1rem;
    border-bottom: 1px solid var(--border);
}
.table-custom tbody tr {
    border-bottom: 1px solid var(--border);
    transition: var(--transition);
}
.table-custom tbody tr:hover { background: var(--bg-subtle); }
.table-custom tbody td { padding: .85rem 1rem; font-size: .9rem; vertical-align: middle; }
.table-custom tbody tr:last-child td { border-bottom: none; }

/* ── Nav Pills (Dashboard tabs) ──────────────────────────── */
.nav-pills-custom { gap: .35rem; }
.nav-pills-custom .nav-link {
    color: var(--text-muted);
    background: transparent;
    border: 1.5px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: .875rem;
    font-weight: 600;
    padding: .5rem 1.1rem;
    transition: var(--transition);
}
.nav-pills-custom .nav-link:hover {
    background: var(--bg-subtle);
    color: var(--purple);
    border-color: rgba(123,47,247,.3);
}
.nav-pills-custom .nav-link.active {
    background: var(--gradient);
    color: #fff;
    border-color: transparent;
    box-shadow: var(--shadow-purple);
}

/* ── Page header ─────────────────────────────────────────── */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 1.75rem;
    flex-wrap: wrap;
    gap: .75rem;
}
.page-header h2 { margin: 0; font-size: 1.5rem; }
.page-title-sub { font-size: .85rem; color: var(--text-muted); margin-top: .2rem; }

/* ── Empty state ─────────────────────────────────────────── */
.empty-state {
    text-align: center;
    padding: 3.5rem 1rem;
}
.empty-state-icon {
    width: 72px; height: 72px;
    background: var(--gradient-subtle);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin: 0 auto 1rem;
    color: var(--purple);
}
.empty-state h5 { color: var(--text-dark); margin-bottom: .5rem; }
.empty-state p  { color: var(--text-muted); font-size: .9rem; max-width: 320px; margin: 0 auto 1.5rem; }

/* ── Alert / Notification ────────────────────────────────── */
.alert-custom {
    border-radius: var(--radius-md);
    border: none;
    font-size: .9rem;
    padding: .9rem 1.1rem;
    display: flex;
    align-items: center;
    gap: .6rem;
}
.alert-success-custom { background: #D1FAE5; color: #065F46; }
.alert-danger-custom  { background: #FEE2E2; color: #991B1B; }
.alert-info-custom    { background: #EEF2FF; color: #3730A3; }
.alert-warn-custom    { background: #FEF3C7; color: #92400E; }

/* ── Footer ──────────────────────────────────────────────── */
.footer-custom {
    background: var(--footer-bg);
    color: rgba(255,255,255,.75);
    padding: 3rem 0 1.5rem;
    margin-top: auto;
}
.footer-brand { font-size: 1.1rem; font-weight: 700; color: #fff; }
.footer-desc  { font-size: .85rem; color: rgba(255,255,255,.55); margin-top: .5rem; max-width: 280px; }
.footer-title { font-size: .7rem; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.4); margin-bottom: .75rem; }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: .45rem; }
.footer-links a { color: rgba(255,255,255,.65); font-size: .875rem; transition: var(--transition); }
.footer-links a:hover { color: #fff; padding-left: 4px; }
.footer-divider { border-color: rgba(255,255,255,.08); margin: 2rem 0 1.25rem; }
.footer-copy { font-size: .8rem; color: rgba(255,255,255,.35); text-align: center; }
.footer-social a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px; height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,.08);
    color: rgba(255,255,255,.65);
    font-size: 1rem;
    transition: var(--transition);
    margin-right: .5rem;
}
.footer-social a:hover {
    background: var(--purple);
    color: #fff;
    transform: translateY(-2px);
}

/* ── Hero section (home) ─────────────────────────────────── */
.hero-section {
    background: linear-gradient(145deg, var(--navy) 0%, #2D1B69 55%, #0E2042 100%);
    border-radius: var(--radius-xl);
    padding: 4rem 2.5rem;
    position: relative;
    overflow: hidden;
    color: #fff;
}
.hero-section::before {
    content: '';
    position: absolute;
    top: -60px; right: -60px;
    width: 340px; height: 340px;
    background: radial-gradient(circle, rgba(123,47,247,.4) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}
.hero-section::after {
    content: '';
    position: absolute;
    bottom: -80px; left: -40px;
    width: 280px; height: 280px;
    background: radial-gradient(circle, rgba(0,198,251,.25) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

/* Ondas fluidas + partículas decorativas do banner */
.hero-deco {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}
.hero-deco .hero-wave {
    position: absolute;
    left: 0; right: 0; bottom: 0;
    width: 100%;
    height: 60%;
    opacity: .9;
}
.hero-deco .hero-dot {
    position: absolute;
    border-radius: 50%;
    background: rgba(155,95,255,.55);
    box-shadow: 0 0 8px rgba(155,95,255,.6);
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: .5rem;
    background: rgba(255,255,255,.1);
    border: 1px solid rgba(255,255,255,.15);
    border-radius: 999px;
    padding: .4rem 1rem;
    font-size: .8rem;
    font-weight: 600;
    color: rgba(255,255,255,.9);
    margin-bottom: 1.25rem;
    backdrop-filter: blur(4px);
}

.hero-title {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 800;
    line-height: 1.1;
    color: #fff;
    margin-bottom: 1.25rem;
}

.hero-lead {
    font-size: 1.05rem;
    color: rgba(255,255,255,.75);
    line-height: 1.7;
    max-width: 480px;
    margin-bottom: 2rem;
}

.hero-logo-wrapper {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hero-logo-wrapper img {
    filter: drop-shadow(0 20px 40px rgba(123,47,247,.4)) brightness(1.1);
    max-height: 340px;
    animation: float 4s ease-in-out infinite;
}
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50%       { transform: translateY(-12px); }
}

/* ── Hero com banner (imagem) ────────────────────────────── */
.hero-banner-section {
    position: relative;
    border-radius: var(--radius-xl);
    overflow: hidden;
    background: linear-gradient(145deg, var(--navy) 0%, #2D1B69 55%, #0E2042 100%);
}
.hero-banner-img {
    display: block;
    width: 100%;
    height: auto;
}
/* Botões sobre o banner (canto inferior esquerdo, como no layout) */
.hero-banner-cta {
    position: absolute;
    left: 5.5%;
    bottom: 23%;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    z-index: 2;
}
/* Faixa de recursos abaixo da imagem */
.hero-banner-features {
    padding: 1.5rem 2rem 2rem;
}
.hero-banner-features .hero-feature .hf-ico {
    background: rgba(255,255,255,.07);
    border: 1px solid rgba(255,255,255,.12);
}

/* Telas menores: botões saem de cima da imagem e ficam abaixo dela */
@media (max-width: 991px) {
    .hero-banner-cta {
        position: static;
        justify-content: center;
        padding: 1.25rem 1rem 0;
    }
}

/* ── Hero: botões em duas linhas ─────────────────────────── */
.hero-cta {
    display: inline-flex;
    align-items: center;
    gap: .75rem;
    padding: .85rem 1.6rem;
    border-radius: var(--radius-md);
    text-align: left;
    transition: var(--transition);
    text-decoration: none;
}
.hero-cta .hero-cta-ico {
    font-size: 1.35rem;
    line-height: 1;
    flex-shrink: 0;
}
.hero-cta .hero-cta-top { font-weight: 700; font-size: 1rem; line-height: 1.1; }
.hero-cta .hero-cta-sub { font-size: .78rem; opacity: .8; }

.hero-cta-primary {
    background: var(--gradient);
    color: #fff;
    box-shadow: var(--shadow-purple);
}
.hero-cta-primary:hover { color: #fff; transform: translateY(-2px); box-shadow: 0 12px 32px rgba(123,47,247,.4); }

.hero-cta-ghost {
    background: rgba(255,255,255,.06);
    color: #fff;
    border: 1.5px solid rgba(255,255,255,.18);
    backdrop-filter: blur(4px);
}
.hero-cta-ghost:hover { color: #fff; background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.3); transform: translateY(-2px); }

/* Traço sob a palavra destacada do título */
.hero-underline {
    display: block;
    width: 230px;
    max-width: 70%;
    height: 10px;
    margin-top: -.35rem;
    background: none;
}
.hero-underline svg { width: 100%; height: 100%; }

/* Anel de brilho atrás da logo */
.hero-logo-wrapper { position: relative; }
.hero-logo-wrapper .hero-ring {
    position: absolute;
    top: 50%; left: 50%;
    width: 78%;
    aspect-ratio: 1;
    transform: translate(-50%, -50%);
    border-radius: 50%;
    border: 1.5px solid rgba(155,95,255,.45);
    box-shadow: 0 0 60px rgba(123,47,247,.35), inset 0 0 60px rgba(0,198,251,.18);
    pointer-events: none;
    z-index: 0;
}
.hero-logo-wrapper img { position: relative; z-index: 1; }

/* Faixa de recursos no rodapé do hero */
.hero-features {
    margin-top: 2.5rem;
    padding-top: 1.75rem;
    border-top: 1px solid rgba(255,255,255,.1);
}
.hero-feature {
    display: flex;
    align-items: center;
    gap: .8rem;
}
.hero-feature .hf-ico {
    width: 44px; height: 44px;
    border-radius: var(--radius-sm);
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem;
    flex-shrink: 0;
    background: rgba(255,255,255,.08);
    border: 1px solid rgba(255,255,255,.12);
}
.hero-feature .hf-title { font-weight: 700; font-size: .92rem; color: #fff; line-height: 1.15; }
.hero-feature .hf-sub   { font-size: .78rem; color: rgba(255,255,255,.6); }
.hero-feature + .hero-feature-sep { }

@media (max-width: 991px) {
    .hero-underline { margin-left: auto; margin-right: auto; }
}

/* ── Sections ────────────────────────────────────────────── */
.section-label {
    display: inline-flex;
    align-items: center;
    gap: .4rem;
    background: rgba(123,47,247,.08);
    color: var(--purple);
    border: 1px solid rgba(123,47,247,.2);
    border-radius: 999px;
    padding: .3rem .9rem;
    font-size: .75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .07em;
    margin-bottom: .75rem;
}

.section-title {
    font-size: clamp(1.5rem, 3vw, 2.1rem);
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: .5rem;
}

/* ── Banner fallback ──────────────────────────────────────── */
.banner-fallback {
    background: var(--gradient-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    width: 100%; height: 100%;
}

/* ── Divider with gradient ───────────────────────────────── */
.divider-gradient {
    height: 3px;
    background: var(--gradient);
    border: none;
    border-radius: 3px;
    margin: 2.5rem 0;
    opacity: .3;
}

/* ── Auth pages ──────────────────────────────────────────── */
.auth-wrapper {
    min-height: calc(100vh - 140px);
    display: flex;
    align-items: center;
}
.auth-card {
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    background: var(--bg-white);
    padding: 2.25rem 2.5rem;
    width: 100%;
}
.auth-header { text-align: center; margin-bottom: 1.75rem; }
.auth-header img { height: 110px; margin-bottom: 1rem; filter: drop-shadow(0 4px 14px rgba(123,47,247,.18)); }
.auth-header h2 { font-size: 1.5rem; margin-bottom: .25rem; }
.auth-header p  { color: var(--text-muted); font-size: .9rem; }

/* ── Scrollbar ───────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(123,47,247,.25); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--purple); }

/* ── Utilities ───────────────────────────────────────────── */
.rounded-custom { border-radius: var(--radius-md) !important; }
.shadow-purple  { box-shadow: var(--shadow-purple) !important; }
.border-gradient {
    border: 2px solid transparent;
    background: linear-gradient(var(--bg-white), var(--bg-white)) padding-box,
                var(--gradient) border-box;
}

/* ── Responsive tweaks ───────────────────────────────────── */
@media (max-width: 768px) {
    .hero-section { padding: 2.5rem 1.5rem; border-radius: var(--radius-lg); }
    .hero-logo-wrapper img { max-height: 220px; }
    .auth-card { padding: 1.75rem 1.25rem; }
    .page-header { flex-direction: column; align-items: flex-start; }
}

/* ============================================================
   DARK THEME — ajustes de componentes com cores fixas
   (badges/alerts pastel ganham versões translúcidas elegantes)
   ============================================================ */
[data-theme="dark"] .navbar-custom .nav-link:hover { background: var(--bg-subtle); }
[data-theme="dark"] .navbar-custom .nav-link.active { background: rgba(155,95,255,.16); }

[data-theme="dark"] .btn-nav-logout { color: #F87171 !important; }
[data-theme="dark"] .btn-nav-logout:hover {
    background: rgba(248,113,113,.14) !important;
    color: #FCA5A5 !important;
}

[data-theme="dark"] .btn-danger-soft {
    background: rgba(248,113,113,.12);
    border-color: rgba(248,113,113,.3);
    color: #FCA5A5;
}
[data-theme="dark"] .btn-danger-soft:hover { background: rgba(248,113,113,.2); color: #FECACA; }

[data-theme="dark"] .btn-ghost:hover { background: var(--bg-subtle); color: var(--purple-light); }

/* Badges de status */
[data-theme="dark"] .badge-aberto,
[data-theme="dark"] .badge-pago    { background: rgba(16,185,129,.18); color: #6EE7B7; }
[data-theme="dark"] .badge-encerrado { background: rgba(239,68,68,.18); color: #FCA5A5; }
[data-theme="dark"] .badge-pendente { background: rgba(245,158,11,.18); color: #FCD34D; }
[data-theme="dark"] .badge-role     { background: rgba(155,95,255,.18); color: var(--purple-light); }

/* Alerts */
[data-theme="dark"] .alert-success-custom { background: rgba(16,185,129,.14); color: #6EE7B7; }
[data-theme="dark"] .alert-danger-custom  { background: rgba(239,68,68,.14);  color: #FCA5A5; }
[data-theme="dark"] .alert-info-custom    { background: rgba(99,102,241,.16); color: #A5B4FC; }
[data-theme="dark"] .alert-warn-custom    { background: rgba(245,158,11,.14); color: #FCD34D; }

/* Stat icons (mantêm legibilidade no escuro) */
[data-theme="dark"] .stat-green { background: rgba(16,185,129,.16); color: #34D399; }

/* Badges genéricos do Bootstrap com texto escuro herdado */
[data-theme="dark"] .table-custom tbody tr:hover { background: var(--bg-subtle); }

/* Imagens/ilustrações muito claras ganham leve atenuação opcional */
[data-theme="dark"] img.dim-on-dark { filter: brightness(.9); }

/* Utilitários do Bootstrap com cor fixa → adaptados ao tema escuro */
[data-theme="dark"] .bg-white,
[data-theme="dark"] .bg-light {
    background-color: var(--bg-white) !important;
    color: var(--text-body);
}
[data-theme="dark"] .card {
    background-color: var(--bg-white);
    border-color: var(--border);
    color: var(--text-body);
}
[data-theme="dark"] .text-dark { color: var(--text-dark) !important; }
[data-theme="dark"] .text-muted { color: var(--text-muted) !important; }
[data-theme="dark"] .border { border-color: var(--border) !important; }
[data-theme="dark"] .table { --bs-table-color: var(--text-body); --bs-table-bg: transparent; }
[data-theme="dark"] hr { border-color: var(--border); }
[data-theme="dark"] .modal-content,
[data-theme="dark"] .dropdown-menu,
[data-theme="dark"] .offcanvas {
    background-color: var(--bg-white);
    color: var(--text-body);
    border-color: var(--border);
}

/* Print global — oculta nav e footer em qualquer página */
@media print {
    .navbar-custom,
    .footer-custom,
    footer,
    nav { display: none !important; }
}
