:root {
  --brand: hsl(229,34%,26%);
  --brand-600: hsl(229,34%,20%);
  --gold: #b8860b;
  --bg: #ffffff;
  --muted: #6b7280;
  --card-radius: 14px;
  --shadow: 0 8px 30px rgba(16,24,40,0.08);
  --maxw: 1100px;
  --gap: 1.25rem;
}

/* Reset + basics */
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }
body {
  font-family: "Inter","Segoe UI",system-ui,-apple-system,Arial,sans-serif;
  color: #111827;
  background: var(--bg);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-top: 72px;
}
a { text-decoration: none; color: inherit; }
img { max-width: 100%; height: auto; display: block; }
.container { max-width: var(--maxw); margin: 0 auto; padding: 0 20px; text-align: center; }

/* Header */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: rgba(255,255,255,0.95);
  backdrop-filter: blur(6px);
  box-shadow: 0 1px 0 rgba(16,24,40,0.04);
  z-index: 1200;
}
.navrow { display: flex; align-items: center; justify-content: space-between; padding: 14px 20px; max-width: var(--maxw); margin: 0 auto; }
.brand { display: flex; align-items: center; gap: 14px; }
.brand h1 { font-size: 1.05rem; color: var(--brand); font-weight: 700; margin-bottom: 4px; }
.brand .small { font-size: 0.85rem; color: var(--muted); letter-spacing: 0.5px; text-transform: uppercase; text-align: left; }
nav ul { display: flex; gap: 18px; align-items: center; }
nav li { list-style: none; }
nav a {
  color: #374151;
  padding: 8px 10px;
  border-radius: 8px;
  font-weight: 600;
  transition: all 0.18s ease;
}
nav a:hover { background-color: #d4af37; color: #0058A3; }

/* Hamburger */
.hamburger { display: none; width: 36px; height: 28px; cursor: pointer; flex-direction: column; justify-content: center; gap: 5px; }
.hamburger span { display: block; height: 3px; border-radius: 3px; background: var(--brand); transition: transform 0.25s ease, opacity 0.18s ease; }
.hamburger.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* HERO / BANNER */
.hero { width: 100%; position: relative; overflow: hidden; z-index: 1100; }
.hero-img-wrapper img.desktop-banner { width: 100%; height: auto; object-fit: cover; display: block; }
.hero-img-wrapper img.mobile-banner { display: none; width: 100%; height: auto; object-fit: cover; }
.hero-banner-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  text-align: center;
  padding: 0 20px;
  max-width: 800px;
  z-index: 10;
}
.hero-banner-text h1, .hero-banner-text p,
.banner-text-desktop, .banner-text-mobile,
.banner-text-mobile h1, .banner-text-mobile p, .banner-text-mobile span {
  font-weight: 400 !important;
  color: #000000;
  font-family: "Inter","Segoe UI",system-ui,-apple-system,Arial,sans-serif;
  line-height: 1.1;
  text-shadow: 0 0 8px rgba(255,255,255,0.5);
}
.hero-banner-text h1 { font-size: clamp(1.45rem, 5vw, 2.5rem); margin-bottom: 10px; }
.hero-banner-text p { font-size: clamp(1rem, 2.5vw, 1.6rem); text-shadow: 0 0 6px rgba(255,255,255,0.4); }
.credito { position: absolute; bottom: 0.5rem; right: 0.5rem; font-size: 0.7rem; background: rgba(255,255,255,0.6); padding: 2px 6px; border-radius: 4px; z-index: 10; }

/* Section titles */
.section-title { text-align:center; margin-bottom:0.5rem; font-size:1.95rem; color:var(--brand); font-weight:700; }
.section-sub { text-align:center; color:var(--muted); margin-bottom:1.25rem; }

/* MAIN COURSES */
.main-courses-section {
  background: #dbe3f0; 
  width: 100%; 
  padding: 30px 0 60px; /* topo 30px, bottom aumentado de 40px para 60px */
  margin: 0 0 30px 0;   /* espaço externo abaixo da tarja */
}

.main-courses-title { 
  text-align: center;
  font-size: 2rem; 
  font-weight: 700; 
  color: var(--brand);
  margin: 30px 0 8px; /* reduz margem superior, conteúdo sobe */
}

.main-courses-sub { 
  display: block; 
  text-align: center; 
  color: var(--muted); 
  margin: 0 auto 40px; /* aumentei de 20px para 40px */
  max-width: 900px; 
  font-size: 1rem; 
}

.main-courses { 
  display: flex; 
  justify-content: space-between; 
  gap: 20px; 
  max-width: var(--maxw); 
  margin: 0 auto; 
  padding: 0 20px; 
  box-sizing: border-box;
}

/* CARDS */
.course-card, .carousel .card, .card {
  outline: 3px solid var(--gold);
  outline-offset: 0;
  border-radius: 16px;
  transition: transform 0.28s ease, box-shadow 0.28s ease, outline-color 0.28s ease;
}
.course-card {
  flex:1;
  text-align:center;
  background:#fff;
  padding:22px;
  box-shadow: var(--shadow);
  position:relative;
}
.course-card:hover {
  transform: translateY(-6px) scale(1.03);
  box-shadow: 0 14px 34px rgba(16,24,40,0.15);
  outline-color: var(--gold);
}
.course-card img { width:100%; height:140px; object-fit:cover; border-radius:10px; margin-bottom:12px; }
.course-card h3 { margin-bottom:10px; color:var(--brand); font-size:1.12rem; }
.course-card p { margin-bottom:12px; color:var(--muted); }
.course-card button {
  background:var(--brand);
  color:#fff;
  padding:10px 18px;
  border-radius:10px;
  border:none;
  font-weight:700;
  cursor:pointer;
  display:block;
  margin:0 auto;
}
.course-card button:hover { background: var(--brand-600); }

/* SECTION IBRESP */
.section-ibresp { 
  background: #e7decb; 
  width: 100%; 
  padding: 35px 0 40px; /* topo 35px, bottom 40px */
  margin-bottom: 30px;  /* distância para a tarja FGV */
}
/* SECTION FGV */
.section-fgv .fgv-bg { 
  width: 100%; 
  background: #d8b4a6; 
  padding: 60px 0 60px; /* topo 60px, bottom 60px */
}

.section-fgv .container { 
  max-width: var(--maxw); 
  margin: 0 auto; 
  padding: 0 20px; 
}

.section-fgv .section-sub { 
  color: #fff; 
  text-align: center; 
  font-size: 1.05rem; 
  max-width: 800px; 
  margin: 10px auto 25px; /* topo 10px, bottom 25px */
}
/* CAROUSEL & CARDS */
.carousel-wrap { max-width:var(--maxw); margin:28px auto; padding:6px 0; position:relative; }
.carousel {
  display:flex;
  gap:var(--gap);
  overflow-x:auto;
  padding:18px;
  scroll-snap-type:x mandatory;
  -webkit-overflow-scrolling:touch;
  scroll-behavior:smooth;
}
.carousel::-webkit-scrollbar { display:none; }
.carousel { scrollbar-width: none; }
.carousel .card {
  flex:0 0 320px;
  background:#fff;
  border-radius:var(--card-radius);
  padding:18px;
  scroll-snap-align:center;
  transition: transform 0.28s ease, box-shadow 0.28s ease;
  box-shadow: 0 6px 20px rgba(16,24,40,0.06);
  text-align:center;
}
.carousel .card:hover { transform: translateY(-6px) scale(1.05); box-shadow: 0 16px 36px rgba(16,24,40,0.18); }
.card img { width:100%; height:170px; object-fit:cover; border-radius:10px; margin-bottom:12px; }
.card h3 { font-size:1.05rem; color:var(--brand); margin-bottom:6px; }
.card p { color:var(--muted); font-size:0.95rem; margin-bottom:10px; }
.card button {
  background:var(--brand);
  color:#fff;
  padding:8px 16px;
  border-radius:10px;
  border:none;
  cursor:pointer;
  font-weight:600;
  display:block;
  margin:0 auto;
}
.card button:hover { background:var(--brand-600); }

/* REMOVE SETAS LATERAIS FLUTUANTES */
.carousel-wrap .desktop-arrow,
.hero .arrow, .hero .arrow-left, .hero .arrow-right,
.hero button.arrow, .hero button.arrow-left, .hero button.arrow-right,
.hero i.fas, .hero i.far, .hero i.fa {
  display: none !important;
}

/* Mantém apenas setas embaixo */
.carousel-arrows-mobile { display:flex; justify-content:center; gap:16px; margin-top:12px; }
.carousel-arrows-mobile .arrow {
  background-color: #fff;
  color: var(--brand);
  border: none;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 1.2rem;
  cursor: pointer;
  transition: background-color 0.2s, color 0.2s;
}
.carousel-arrows-mobile .arrow:hover { background-color: var(--gold); color: var(--brand); }

/* MODAL */
.modal { display: none; position: fixed; z-index: 3000; inset: 0; background: rgba(3,6,23,0.8); backdrop-filter: blur(4px); justify-content: center; align-items: center; opacity: 0; pointer-events: none; transition: opacity 180ms ease; }
.modal.show { display: flex; opacity: 1; pointer-events: auto; }
.modal-content { position: relative; max-width: 920px; width: calc(100% - 40px); max-height: 90vh; background: transparent; border-radius: 16px; display:flex; justify-content:center; align-items:center; overflow:hidden; padding:0; }
.modal img { display:block; max-width:90vw; max-height:80vh; margin:0; padding:0; border:3px solid #000; box-shadow:0 0 10px rgba(0,0,0,0.5); object-fit:cover; }
#modal-img.loaded { opacity:1; border:6px solid var(--gold); border-radius:8px; box-sizing:border-box; }
.close-modal { position: absolute; top:12px; right:12px; background: rgba(0,0,0,0.6); color:#fff; font-size:1.6rem; border:none; border-radius:50%; width:36px; height:36px; cursor:pointer; display:flex; align-items:center; justify-content:center; transition: background 0.2s; z-index:3100; }
.close-modal:hover { background: rgba(0,0,0,0.8); }

/* Responsividade */
@media (max-width:1024px){
  .carousel .card{ flex:0 0 300px; }
  .main-courses{ flex-direction:column; gap:16px; padding:20px; }
}
@media (max-width:768px){
  .hamburger { display: flex; }
  nav ul { display: none; }
  nav ul.show { display:flex; flex-direction:column; gap:12px; background: rgba(255,255,255,0.95); position:absolute; top:100%; right:0; padding:12px; border-radius:8px; box-shadow:0 6px 20px rgba(0,0,0,0.08); }

  .hero-img-wrapper img.desktop-banner { display: none; }
  .hero-img-wrapper img.mobile-banner { display: block; }
  .banner-text-desktop { display: none; }
  .banner-text-mobile {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: absolute;
    top: 55%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    max-width: 85%;
    padding: 0 10px;
    z-index: 10;
  }
  .banner-text-mobile .banner-title { font-size: clamp(1.45rem, 5vw, 2.5rem); font-weight:400; color:#000; line-height:1.1; text-shadow:0 0 8px rgba(255,255,255,0.5); margin-bottom:6px; }
  .banner-text-mobile .banner-subtitle { font-size: clamp(1rem,2.5vw,1.6rem); font-weight:400; color:#000; line-height:1.1; text-shadow:0 0 6px rgba(255,255,255,0.4); }
}
