@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:ital,wght@0,400;0,700;0,900;1,400&family=Poppins:wght@300;400;500;600;700&display=swap');

/* ════════════════════════════════════════════════════════════════
   Design System — Avaliação Letiva v2.1
   Baseado na página de welcome (identidade visual)
   ════════════════════════════════════════════════════════════════ */

:root {
  /* Cores */
  --av-vermelho:        #CE1126;
  --av-vermelho-escuro: #9E0B1A;
  --av-vermelho-suave:  rgba(206,17,38,0.08);
  --av-cinza-escuro:    #1A1A2E;
  --av-cinza-texto:     #4A4A5A;
  --av-cinza-suave:     #94a3b8;
  --av-dourado:         #C4A263;
  --av-fundo:           #F5F0EB;
  --av-branco:          #FFFFFF;
  --av-card:            rgba(255,255,255,0.75);
  --av-borda:           rgba(206,17,38,0.12);

  /* Tipografia */
  --font-display: 'Playfair Display', Georgia, serif;
  --font-body:    'Poppins', 'Segoe UI', sans-serif;

  /* Espaçamentos */
  --radius-sm:  10px;
  --radius-md:  14px;
  --radius-lg:  18px;
  --radius-xl:  20px;
  --radius-full: 999px;

  /* Sombras */
  --shadow-card: 0 1px 2px rgba(0,0,0,0.04), 0 8px 40px rgba(0,0,0,0.04), 0 0 0 1px rgba(0,0,0,0.03);
  --shadow-hover: 0 12px 32px rgba(206,17,38,0.08);
}

/* ═════════ Body ═════════ */
body {
  font-family: var(--font-body);
  color: var(--av-cinza-escuro);
  background: linear-gradient(180deg, #FAFBFC 0%, var(--av-fundo) 100%);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ═════════ Fundo padrão para páginas internas ═════════ */
.page-wrapper {
  display: flex;
  flex-direction: column;
  min-height: calc(100vh - 48px);
}

/* ═════════ Header / Top bar ═════════ */
.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 0 0.5rem;
}

.page-header .brand {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--av-cinza-escuro);
  color: #fff;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.05em;
  flex-shrink: 0;
}

.page-header .brand-label {
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--av-cinza-suave);
}

.page-header .brand-name {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--av-cinza-escuro);
  line-height: 1.2;
}

.page-header .header-link {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--av-cinza-suave);
  text-decoration: none;
  transition: color 0.2s;
}
.page-header .header-link:hover { color: var(--av-cinza-escuro); }

/* ═════════ Títulos de secção ═════════ */
.section-title {
  font-family: var(--font-display);
  font-weight: 900;
  font-size: 2.2rem;
  letter-spacing: -0.03em;
  line-height: 1.1;
  color: var(--av-cinza-escuro);
}

.section-title em {
  font-style: italic;
  font-weight: 400;
  color: var(--av-vermelho);
}

.section-subtitle {
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--av-cinza-texto);
}

.section-label {
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--av-vermelho-escuro);
}

.sentinel {
  width: 48px;
  height: 3px;
  background: var(--av-dourado);
  border-radius: 2px;
}

/* ═════════ Cards ═════════ */
.av-card {
  background: var(--av-card);
  backdrop-filter: blur(8px);
  border: 1px solid var(--av-borda);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  transition: all 0.3s ease;
}

.av-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  border-color: rgba(206,17,38,0.2);
}

.av-card-solid {
  background: var(--av-branco);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-card);
}

/* ═════════ Botões ═════════ */
.av-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border-radius: var(--radius-sm);
  padding: 0.65rem 1.25rem;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none;
  cursor: pointer;
  transition: all 0.25s ease;
  border: none;
  outline: none;
}

.av-btn-primary {
  background: var(--av-cinza-escuro);
  color: #fff;
}
.av-btn-primary:hover { background: var(--av-vermelho); }

.av-btn-secondary {
  background: var(--av-branco);
  color: var(--av-cinza-escuro);
  border: 1px solid rgba(0,0,0,0.08);
}
.av-btn-secondary:hover {
  background: var(--av-fundo);
  border-color: rgba(206,17,38,0.2);
}

.av-btn-accent {
  background: var(--av-vermelho);
  color: #fff;
}
.av-btn-accent:hover { background: var(--av-vermelho-escuro); }

.av-btn-ghost {
  background: transparent;
  color: var(--av-cinza-texto);
  padding: 0.5rem 0.8rem;
  font-size: 0.78rem;
}
.av-btn-ghost:hover { color: var(--av-vermelho); }

/* Ícone no botão */
.av-btn .icon { width: 18px; height: 18px; stroke-width: 2; }

/* ═════════ Formulários ═════════ */
.av-input {
  width: 100%;
  background: #FAFAFA;
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.9rem;
  font-family: var(--font-body);
  font-size: 0.88rem;
  color: var(--av-cinza-escuro);
  transition: all 0.25s ease;
  outline: none;
}

.av-input:focus {
  border-color: var(--av-vermelho);
  box-shadow: 0 0 0 3px rgba(206,17,38,0.08);
  background: var(--av-branco);
}

.av-input-label {
  display: block;
  margin-bottom: 0.3rem;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--av-cinza-suave);
}

/* ═════════ Badges ═════════ */
.av-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  border: 1px solid var(--av-borda);
  font-size: 0.65rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--av-vermelho-escuro);
  background: rgba(206,17,38,0.04);
}

.av-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 600;
}

.av-status-open     { background: #dcfce7; color: #166534; }
.av-status-closed   { background: #f1f5f9; color: #475569; }
.av-status-draft    { background: #fef3c7; color: #92400e; }

/* ═════════ Tabelas ═════════ */
.av-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.82rem;
}

.av-table th {
  padding: 0.65rem 0.8rem;
  text-align: left;
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--av-cinza-suave);
  border-bottom: 1px solid rgba(0,0,0,0.06);
}

.av-table td {
  padding: 0.7rem 0.8rem;
  border-bottom: 1px solid rgba(0,0,0,0.04);
  color: var(--av-cinza-texto);
}

.av-table tr:hover td {
  background: rgba(206,17,38,0.02);
}

/* ═════════ Ícones SVG padrão ═════════ */
.av-icon {
  width: 20px;
  height: 20px;
  color: var(--av-vermelho);
  stroke-width: 1.8;
  flex-shrink: 0;
}

/* ═════════ Links utilitários ═════════ */
.av-link {
  color: var(--av-cinza-texto);
  font-size: 0.78rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s;
}
.av-link:hover { color: var(--av-vermelho); }
.av-link-primary { color: var(--av-vermelho); }

/* ═════════ Footer de página ═════════ */
.page-footer {
  padding: 0.75rem 0 0.5rem;
  text-align: center;
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--av-cinza-suave);
}

/* ═════════ Animações ═════════ */
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.animate-fade-1 { opacity: 0; animation: fadeSlideUp 0.7s cubic-bezier(0.22,1,0.36,1) 0.1s  forwards; }
.animate-fade-2 { opacity: 0; animation: fadeSlideUp 0.7s cubic-bezier(0.22,1,0.36,1) 0.22s forwards; }
.animate-fade-3 { opacity: 0; animation: fadeSlideUp 0.7s cubic-bezier(0.22,1,0.36,1) 0.34s forwards; }
.animate-fade-4 { opacity: 0; animation: fadeSlideUp 0.7s cubic-bezier(0.22,1,0.36,1) 0.46s forwards; }

/* ═════════ Responsivo (mobile compacto) ═════════ */
@media (max-width: 640px) {
  .section-title { font-size: 1.8rem; }
  .av-card { padding: 1rem; }
}
