/* IIT Ropar — Research X Impact
   Visual adaptation of the supplied IIT Roorkee Research X Impact reference.
*/

:root {
  --ink: #111318;
  --muted: #646a73;
  --paper: #f7f5f0;
  --white: #ffffff;
  --accent: #c91f2d;
  --accent-dark: #991723;
  --navy: #101a2d;
  --line: #dedbd3;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--paper);
  font-family: "DM Sans", Arial, sans-serif;
  line-height: 1.65;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--accent); }

.site-header {
  background: #fff;
  position: relative;
  z-index: 1000;
}

.brand-row {
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 15px;
}

.brand-logo {
  width: 74px;
  height: 74px;
  object-fit: contain;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.brand-hindi {
  font-size: 17px;
  font-weight: 700;
}

.brand-english {
  font-size: 15px;
  letter-spacing: .04em;
  font-weight: 700;
}

.brand-text small {
  color: var(--muted);
  margin-top: 4px;
}

.header-links {
  display: flex;
  gap: 22px;
  font-size: 14px;
  font-weight: 600;
}

.nav-bar {
  background: var(--navy);
  padding: 8px 0;
}

.nav-link {
  color: rgba(255,255,255,.82) !important;
  font-weight: 600;
  font-size: 14px;
  padding: 10px 13px !important;
}

.nav-link:hover,
.nav-link.active {
  color: #fff !important;
}

.nav-cta {
  font-weight: 700;
}

.hero {
  position: relative;
  min-height: 720px;
  background: #111;
}

.hero .carousel,
.hero .carousel-inner,
.hero .carousel-item {
  height: 720px;
}

.hero-image {
  height: 100%;
  object-fit: cover;
  object-position: center;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  z-index: 2;
  background:
    linear-gradient(90deg, rgba(7,12,22,.91) 0%, rgba(7,12,22,.70) 40%, rgba(7,12,22,.22) 75%, rgba(7,12,22,.15) 100%),
    linear-gradient(0deg, rgba(0,0,0,.48), transparent 45%);
  pointer-events: none;
}

.hero-content {
  position: absolute;
  z-index: 3;
  inset: 0;
  display: flex;
  align-items: center;
}

.hero-copy {
  max-width: 780px;
  color: #fff;
  padding: 80px 0 60px;
}

.eyebrow,
.section-kicker {
  font-size: 12px;
  letter-spacing: .22em;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 14px;
}

.eyebrow { color: #fff; opacity: .86; }

.hero h1 {
  margin: 0;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(50px, 6.2vw, 88px);
  line-height: .88;
  letter-spacing: -.04em;
}

.hero h1 span { color: #ef4752; }

.hero-rule {
  width: 86px;
  height: 4px;
  background: #fff;
  margin: 30px 0 20px;
}

.hero-subtitle {
  font-size: clamp(19px, 2vw, 26px);
  max-width: 650px;
  margin-bottom: 32px;
}

.event-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 35px;
  margin-bottom: 30px;
}

.event-meta > div {
  display: flex;
  flex-direction: column;
  border-left: 2px solid rgba(255,255,255,.5);
  padding-left: 14px;
}

.event-meta strong {
  font-size: 13px;
  letter-spacing: .06em;
}

.event-meta span {
  font-size: 13px;
  opacity: .78;
}

.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
}

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

.carousel-indicators { z-index: 5; }

.section-pad { padding: 105px 0; }

.intro {
  background: var(--paper);
}

h2 {
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(40px, 5vw, 66px);
  line-height: 1.04;
  letter-spacing: -.025em;
}

h2 em {
  color: var(--accent);
  font-style: normal;
}

.lead {
  color: var(--muted);
  font-size: 17px;
  text-align: justify;
  line-height: 1.7;
}

.intro p,
.impact p,
.timeline p,
.segment-card p,
.committee .lead {
  text-align: justify;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.feature-grid article {
  padding: 32px 28px;
  border-right: 1px solid var(--line);
}

.feature-grid article:last-child { border-right: 0; }

.icon {
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff;
  background: var(--accent);
  font-size: 20px;
  margin-bottom: 22px;
}

.feature-grid h3,
.segment-card h3,
.timeline h3 {
  font-size: 21px;
  font-weight: 700;
}

.feature-grid p,
.segment-card p,
.timeline p {
  color: var(--muted);
  margin-bottom: 0;
}

.dark-section {
  background: var(--navy);
  color: #fff;
}

.section-kicker.light { color: #f05460; }

.segment-card {
  height: 100%;
  padding: 35px;
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.035);
  transition: transform .25s ease, border-color .25s ease, background .25s ease;
}

.segment-card:hover {
  transform: translateY(-6px);
  border-color: rgba(255,255,255,.4);
  background: rgba(255,255,255,.07);
}

.segment-card span {
  display: block;
  color: #ef4752;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .14em;
  margin-bottom: 25px;
}

.segment-card h3 { color: #fff; }

.impact {
  background: #fff;
}

.impact-list {
  border-top: 1px solid var(--line);
}

.impact-list > div {
  display: grid;
  grid-template-columns: 60px 1fr;
  gap: 20px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
}

.impact-list strong {
  color: var(--accent);
  font-size: 13px;
}

.impact-list span {
  font-weight: 600;
}

.schedule { background: var(--paper); }

.timeline {
  border-top: 1px solid var(--line);
}

.time-row {
  display: grid;
  grid-template-columns: 150px 1fr;
  gap: 30px;
  padding: 27px 0;
  border-bottom: 1px solid var(--line);
}

.time-row time {
  font-weight: 700;
  color: var(--accent);
  font-size: 14px;
}

.time-row h3 { margin-bottom: 5px; }

.registration {
  background: var(--navy);
  color: #fff;
}

.registration-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 50px;
  padding: 60px;
  border: 1px solid rgba(255,255,255,.16);
  background:
    radial-gradient(circle at 90% 20%, rgba(201,31,45,.32), transparent 30%),
    rgba(255,255,255,.03);
}

.registration-box h2 {
  max-width: 750px;
}

.registration-box p {
  color: rgba(255,255,255,.7);
  max-width: 720px;
}

.contact {
  background: #fff;
}

.contact h2 {
  font-family: "DM Sans", Arial, sans-serif;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: 0.01em;
  line-height: 1.5;
  margin: 0 0 10px;
  color: var(--ink);
}

.contact .mt-3 {
  font-family: "DM Sans", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.7;
  text-align: left;
  color: var(--ink);
  font-weight: 500;
  margin: 0;
}

.contact-card {
  border-left: 3px solid var(--accent);
  padding: 18px 25px;
  background: var(--paper);
}

.contact-card p {
  margin: 0;
  padding: 9px 0;
  font-family: "DM Sans", Arial, sans-serif;
  font-weight: 600;
  font-size: 16px;
  line-height: 1.55;
}

.contact-card i {
  color: var(--accent);
  margin-right: 8px;
}

footer {
  background: #080d17;
  color: rgba(255,255,255,.62);
  padding: 22px 0;
  font-size: 13px;
}

.back-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 45px;
  height: 45px;
  border: 0;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: none;
  place-items: center;
  z-index: 100;
  box-shadow: 0 8px 25px rgba(0,0,0,.18);
}

.back-top.show { display: grid; }

code {
  color: var(--accent-dark);
}

@media (max-width: 991.98px) {
  .brand-row { min-height: 80px; }
  .header-links { display: none; }
  .nav-bar .navbar-collapse { padding: 12px 0 4px; }
  .nav-cta { margin: 8px 0; }
  .hero, .hero .carousel, .hero .carousel-inner, .hero .carousel-item { height: 650px; }
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
  .feature-grid article:nth-child(2) { border-right: 0; }
  .feature-grid article:nth-child(-n+2) { border-bottom: 1px solid var(--line); }
  .registration-box { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 575.98px) {
  .brand-logo { width: 58px; height: 58px; }
  .brand-hindi { font-size: 13px; }
  .brand-english { font-size: 11px; }
  .brand-text small { font-size: 10px; }
  .hero, .hero .carousel, .hero .carousel-inner, .hero .carousel-item { height: 620px; }
  .hero-copy { padding: 50px 20px; }
  .hero h1 { font-size: 58px; }
  .hero-subtitle { font-size: 17px; }
  .event-meta { gap: 15px; }
  .section-pad { padding: 75px 0; }
  .feature-grid { grid-template-columns: 1fr; }
  .feature-grid article { border-right: 0; border-bottom: 1px solid var(--line); }
  .feature-grid article:last-child { border-bottom: 0; }
  .time-row { grid-template-columns: 1fr; gap: 8px; }
  .registration-box { padding: 35px 25px; }
}

.logo-fallback-visible::before {
  content: "IIT ROPAR";
  display: grid;
  place-items: center;
  width: 74px;
  height: 74px;
  border: 2px solid var(--accent);
  border-radius: 50%;
  color: var(--accent);
  font-weight: 800;
  font-size: 12px;
  letter-spacing: .06em;
}
@media (max-width: 575.98px) {
  .logo-fallback-visible::before {
    width: 58px;
    height: 58px;
    font-size: 10px;
  }
}

/* User-provided campus video slider */
.video-slider .carousel-item {
  position: relative;
  overflow: hidden;
  background: #080d17;
}

.hero-video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  background: #080d17;
}

.video-caption {
  position: absolute;
  right: 8%;
  bottom: 72px;
  z-index: 4;
  color: #fff;
  text-align: right;
  max-width: 430px;
  text-shadow: 0 2px 18px rgba(0,0,0,.45);
}

.video-caption span {
  display: block;
  font-size: 11px;
  letter-spacing: .18em;
  font-weight: 700;
  margin-bottom: 8px;
}

.video-caption strong {
  display: block;
  font-family: "Playfair Display", Georgia, serif;
  font-size: clamp(22px, 3vw, 38px);
  line-height: 1.05;
}

@media (max-width: 575.98px) {
  .video-caption {
    right: 20px;
    bottom: 58px;
    max-width: 300px;
  }

  .video-caption strong {
    font-size: 24px;
  }
}

/* ANRF + IIT Ropar hero branding */
.hero-partner-logos {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-bottom: 14px;
}

.hero-logo-card {
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(255,255,255,.65);
  border-radius: 10px;
  padding: 8px 12px;
  box-shadow: 0 8px 28px rgba(0,0,0,.18);
}

.anrf-logo-card img {
  width: 170px;
  height: auto;
  display: block;
}

.iitrpr-hero-logo-card img {
  width: 78px;
  height: 78px;
  object-fit: contain;
  display: block;
}

.hero-logo-plus {
  color: #fff;
  font-size: 34px;
  font-weight: 800;
  line-height: 1;
  text-shadow: 0 2px 12px rgba(0,0,0,.35);
}

.hero-sponsor-title {
  font-size: clamp(22px, 3.1vw, 38px);
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1;
  margin-bottom: 12px;
  color: #fff;
  text-shadow: 0 2px 16px rgba(0,0,0,.35);
}

.hero-subtitle.sponsor-line {
  max-width: 820px;
  font-size: clamp(15px, 1.45vw, 19px);
  line-height: 1.45;
}

.hero-subtitle.sponsor-line a {
  color: #fff;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.hero-subtitle.sponsor-line a:hover {
  color: #ffd7da;
}

.hero-subtitle.sponsor-line a.dreams-highlight {
  font-size: 1.35em;
  font-weight: 800;
  letter-spacing: 0.02em;
  color: #fff;
  background: linear-gradient(90deg, rgba(239,71,82,0.55), rgba(201,31,45,0.35));
  padding: 0.12em 0.4em;
  border-radius: 4px;
  text-decoration: none;
  box-shadow: 0 2px 12px rgba(0,0,0,0.25);
  display: inline-block;
  line-height: 1.25;
  vertical-align: baseline;
}

.hero-subtitle.sponsor-line a.dreams-highlight:hover {
  color: #fff;
  background: linear-gradient(90deg, rgba(239,71,82,0.75), rgba(201,31,45,0.55));
}

.committee {
  background: var(--paper);
}

.committee-card {
  height: 100%;
  padding: 32px;
  background: #fff;
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent);
  transition: transform .25s ease, box-shadow .25s ease;
}

.committee-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0,0,0,.08);
}

.committee-number {
  display: inline-block;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: .14em;
  margin-bottom: 20px;
}

.committee-card h3 {
  font-size: 21px;
  font-weight: 700;
  margin-bottom: 10px;
}

.committee-card p {
  color: var(--muted);
  margin: 0;
}

.committee-note {
  padding: 15px 18px;
  border-left: 3px solid var(--accent);
  background: #fff;
  color: var(--muted);
  font-size: 14px;
}

@media (max-width: 575.98px) {
  .hero-partner-logos { gap: 10px; }
  .hero-logo-card { padding: 6px 8px; border-radius: 8px; }
  .anrf-logo-card img { width: 125px; }
  .iitrpr-hero-logo-card img { width: 58px; height: 58px; }
  .hero-logo-plus { font-size: 25px; }
  .hero-sponsor-title { font-size: 28px; }
}

/* Header partner branding */
.header-partner-logos {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-shrink: 0;
}

.header-anrf-logo {
  width: 112px;
  height: 62px;
  object-fit: contain;
  display: block;
}

.header-logo-plus {
  color: var(--accent);
  font-size: 20px;
  font-weight: 800;
}

@media (max-width: 575.98px) {
  .header-anrf-logo { width: 88px; height: 50px; }
  .header-partner-logos { gap: 5px; }
  .header-logo-plus { font-size: 16px; }
}


/* Final responsive refinements */
.hero h1 {
  /* Smaller, more balanced Research X Impact title */
  font-size: clamp(42px, 5vw, 72px);
  line-height: .9;
}

.video-caption {
  right: clamp(18px, 5vw, 72px);
  bottom: clamp(28px, 5vw, 58px);
  width: auto;
  max-width: calc(100% - 36px);
  display: flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-align: right;
}

.video-caption span,
.video-caption strong {
  display: inline;
  white-space: nowrap;
}

.video-caption span {
  margin-bottom: 0;
  font-size: clamp(9px, 1vw, 12px);
  flex: 0 0 auto;
}

.video-caption strong {
  font-size: clamp(14px, 2vw, 27px);
  line-height: 1;
  flex: 0 1 auto;
}

/* Keep the main page comfortable on tablets and phones. */
@media (max-width: 991.98px) {
  .brand-row {
    min-height: 78px;
    padding: 8px 0;
  }

  .brand {
    min-width: 0;
  }

  .header-partner-logos {
    gap: 5px;
  }

  .header-anrf-logo {
    width: 88px;
    height: 50px;
  }

  .brand-logo {
    width: 58px;
    height: 58px;
  }

  .brand-text {
    min-width: 0;
  }

  .brand-hindi,
  .brand-english,
  .brand-text small {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .brand-hindi { font-size: 14px; }
  .brand-english { font-size: 12px; }
  .brand-text small { font-size: 10px; }

  .nav-bar .container-fluid {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  .hero,
  .hero .carousel,
  .hero .carousel-inner,
  .hero .carousel-item {
    height: min(650px, 72vh);
    min-height: 540px;
  }

  .hero-content {
    align-items: center;
  }

  .hero-copy {
    width: min(760px, 100%);
    padding: 50px 20px 70px;
  }

  .hero-subtitle.sponsor-line {
    max-width: 680px;
    font-size: clamp(14px, 2vw, 18px);
  }

  .event-meta {
    gap: 18px 28px;
  }
}

@media (max-width: 575.98px) {
  .brand-row {
    min-height: 72px;
  }

  .brand {
    gap: 8px;
    max-width: calc(100% - 8px);
  }

  .header-anrf-logo {
    width: 68px;
    height: 42px;
  }

  .header-logo-plus {
    font-size: 15px;
  }

  .brand-logo {
    width: 48px;
    height: 48px;
  }

  .brand-hindi { font-size: 11px; }
  .brand-english { font-size: 9px; letter-spacing: .02em; }
  .brand-text small { font-size: 8px; margin-top: 2px; }

  .hero,
  .hero .carousel,
  .hero .carousel-inner,
  .hero .carousel-item {
    height: 600px;
    min-height: 520px;
  }

  .hero-copy {
    padding: 35px 16px 80px;
  }

  .hero h1 {
    font-size: clamp(38px, 12vw, 48px);
    letter-spacing: -.045em;
  }

  .hero-rule {
    width: 62px;
    height: 3px;
    margin: 22px 0 15px;
  }

  .hero-subtitle.sponsor-line {
    font-size: 14px;
    line-height: 1.35;
    margin-bottom: 22px;
  }

  .event-meta {
    gap: 12px;
    margin-bottom: 22px;
  }

  .event-meta > div {
    width: 100%;
  }

  .video-caption {
    right: 12px;
    bottom: 38px;
    max-width: calc(100% - 24px);
    gap: 7px;
  }

  .video-caption span {
    font-size: 8px;
    letter-spacing: .10em;
  }

  .video-caption strong {
    font-size: 14px;
  }

  .carousel-indicators {
    bottom: 10px;
  }
}

@media (max-width: 380px) {
  .header-partner-logos .header-anrf-logo {
    width: 58px;
  }

  .header-partner-logos .brand-logo {
    width: 42px;
    height: 42px;
  }

  .brand-hindi { font-size: 10px; }
  .brand-english { font-size: 8px; }

  .video-caption {
    gap: 5px;
  }

  .video-caption span { font-size: 7px; }
  .video-caption strong { font-size: 12px; }
}

/* Slider and primary navigation sizing refinement */
.nav-link {
  font-size: 16px;
  font-weight: 650;
  padding: 11px 14px !important;
}

.hero,
.hero .carousel,
.hero .carousel-inner,
.hero .carousel-item {
  height: 650px;
}

.hero {
  min-height: 650px;
}

@media (max-width: 991.98px) {
  .nav-link {
    font-size: 16px;
    padding: 10px 12px !important;
  }

  .hero,
  .hero .carousel,
  .hero .carousel-inner,
  .hero .carousel-item {
    height: 590px;
    min-height: 500px;
  }
}

@media (max-width: 575.98px) {
  .nav-link {
    font-size: 15px;
    padding: 9px 10px !important;
  }

  .hero,
  .hero .carousel,
  .hero .carousel-inner,
  .hero .carousel-item {
    height: 540px;
    min-height: 480px;
  }
}

/* Organising committee photo cards */
.committee-photos {
  margin-bottom: 0.5rem;
}

.committee-photo-card {
  height: 100%;
  background: #fff;
  border: 1px solid var(--line);
  border-top: 3px solid var(--accent);
  padding: 0 0 22px;
  text-align: center;
  transition: transform .25s ease, box-shadow .25s ease;
  overflow: hidden;
}

.committee-photo-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 35px rgba(0,0,0,.08);
}

.committee-photo-wrap {
  width: 100%;
  aspect-ratio: 3 / 4;
  overflow: hidden;
  background: #f0eeea;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.committee-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  display: block;
}

.committee-photo-card h3 {
  font-size: 14px;
  font-weight: 700;
  margin: 0 10px 6px;
  line-height: 1.35;
  min-height: 2.7em;
}

.committee-photo-card p {
  color: var(--muted);
  font-size: 12px;
  margin: 0 10px;
  line-height: 1.4;
  min-height: 2.8em;
}

@media (max-width: 991.98px) {
  .committee-photo-card h3 {
    font-size: 14px;
  }
  .committee-photo-card p {
    font-size: 11px;
  }
}

@media (max-width: 575.98px) {
  .committee-photo-wrap {
    aspect-ratio: 3 / 4;
  }
}

/* ========== Enhanced responsive refinements ========== */

html {
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
}

body {
  overflow-x: hidden;
}

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

/* Header: prevent overflow on small screens */
@media (max-width: 991.98px) {
  .brand-row {
    flex-wrap: wrap;
    min-height: auto;
    padding: 10px 0;
    gap: 12px;
  }

  .header-links {
    display: none;
  }

  .header-partner-logos {
    flex-shrink: 0;
  }

  .brand-text {
    max-width: calc(100vw - 160px);
  }

  .brand-hindi {
    font-size: 13px;
  }

  .brand-english {
    font-size: 11px;
    letter-spacing: 0.02em;
  }

  .brand-text small {
    font-size: 10px;
  }
}

@media (max-width: 575.98px) {
  .brand-row {
    padding: 8px 0;
  }

  .header-anrf-logo {
    width: 72px;
    height: 40px;
  }

  .header-logo-plus {
    font-size: 14px;
  }

  .brand-logo {
    width: 42px;
    height: 42px;
  }

  .brand-text {
    max-width: calc(100vw - 140px);
  }

  .brand-hindi {
    font-size: 11px;
  }

  .brand-english {
    font-size: 9px;
  }

  .brand-text small {
    font-size: 8px;
  }
}

/* Hero responsive */
@media (max-width: 991.98px) {
  .hero,
  .hero .carousel,
  .hero .carousel-inner,
  .hero .carousel-item {
    height: 560px;
    min-height: 480px;
  }

  .hero-copy {
    padding: 40px 12px 70px;
    max-width: 100%;
  }

  .hero-sponsor-title {
    font-size: clamp(18px, 4vw, 28px);
  }

  .hero h1 {
    font-size: clamp(36px, 10vw, 56px);
  }

  .event-meta {
    flex-direction: column;
    gap: 14px;
  }

  .event-meta > div {
    width: 100%;
  }
}

@media (max-width: 575.98px) {
  .hero,
  .hero .carousel,
  .hero .carousel-inner,
  .hero .carousel-item {
    height: 520px;
    min-height: 460px;
  }

  .hero-copy {
    padding: 28px 8px 64px;
  }

  .hero h1 {
    font-size: clamp(32px, 11vw, 44px);
    line-height: 0.95;
  }

  .hero-subtitle.sponsor-line {
    font-size: 13px;
    line-height: 1.4;
  }

  .btn-lg {
    font-size: 14px;
    padding: 0.55rem 1.2rem;
  }

  .video-caption {
    right: 10px;
    bottom: 48px;
    max-width: calc(100% - 20px);
  }

  .video-caption strong {
    font-size: 13px;
  }

  .video-caption span {
    font-size: 8px;
  }
}

/* Sections */
@media (max-width: 991.98px) {
  .section-pad {
    padding: 70px 0;
  }

  h2 {
    font-size: clamp(28px, 6vw, 44px);
  }
}

@media (max-width: 575.98px) {
  .section-pad {
    padding: 55px 0;
  }

  .container {
    padding-left: 16px;
    padding-right: 16px;
  }
}

/* Feature grid already handled; reinforce */
@media (max-width: 767.98px) {
  .feature-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 480px) {
  .feature-grid {
    grid-template-columns: 1fr;
  }
}

/* Segments */
@media (max-width: 575.98px) {
  .segment-card {
    padding: 24px 20px;
  }
}

/* Schedule timeline */
@media (max-width: 767.98px) {
  .time-row {
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 18px 0;
  }

  .time-row time {
    font-size: 13px;
  }

  .time-row h3 {
    font-size: 17px;
  }
}

/* Committee photos – clearer breakpoints */
@media (max-width: 1199.98px) {
  .committee-photos .col-lg-2 {
    flex: 0 0 33.333%;
    max-width: 33.333%;
  }
}

@media (max-width: 767.98px) {
  .committee-photos .col-md-4 {
    flex: 0 0 50%;
    max-width: 50%;
  }

  .committee-photo-card h3 {
    font-size: 13px;
    min-height: 2.4em;
  }

  .committee-photo-card p {
    font-size: 11px;
    min-height: 2.4em;
  }
}

@media (max-width: 400px) {
  .committee-photos .col-6 {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .committee-photo-wrap {
    aspect-ratio: 4 / 5;
    max-height: 280px;
  }
}

/* Registration box */
@media (max-width: 767.98px) {
  .registration-box {
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
    padding: 36px 22px;
  }

  .registration-box h2 {
    font-size: clamp(26px, 7vw, 40px);
  }
}

/* Contact */
@media (max-width: 767.98px) {
  .contact .row {
    gap: 1.5rem !important;
  }

  .contact h2,
  .contact .mt-3,
  .contact-card p {
    font-size: 15px;
  }
}

/* Navigation CTA on mobile */
@media (max-width: 991.98px) {
  .nav-cta {
    display: inline-block;
    margin: 10px 0 4px;
    width: auto;
  }

  .navbar-nav {
    padding-top: 8px;
  }

  .nav-link {
    padding: 10px 4px !important;
  }
}

/* Back to top – keep reachable on mobile */
@media (max-width: 575.98px) {
  .back-top {
    right: 14px;
    bottom: 14px;
    width: 42px;
    height: 42px;
  }
}

/* Prevent long words from overflowing */
.timeline p,
.segment-card p,
.committee-photo-card p,
.contact-card p {
  overflow-wrap: break-word;
  word-wrap: break-word;
}

/* ========== Mobile navigation fix ========== */
.site-header {
  position: relative;
  z-index: 1050;
}

.nav-bar {
  position: relative;
  z-index: 1051;
}

.navbar-toggler {
  border: 1px solid rgba(255,255,255,0.45) !important;
  padding: 0.4rem 0.65rem;
  z-index: 1052;
  position: relative;
}

.navbar-toggler:focus {
  box-shadow: 0 0 0 0.2rem rgba(255,255,255,0.25);
}

.navbar-toggler-icon {
  filter: invert(1) brightness(2);
}

/* Ensure collapsed menu is visible and clickable above the hero */
@media (max-width: 991.98px) {
  .navbar-collapse {
    background: var(--navy);
    margin: 0 -12px;
    padding: 12px 16px 16px !important;
    border-top: 1px solid rgba(255,255,255,0.12);
    position: relative;
    z-index: 1052;
  }

  .navbar-collapse.show,
  .navbar-collapse.collapsing {
    display: block;
  }

  .navbar-nav {
    width: 100%;
  }

  .navbar-nav .nav-link {
    display: block;
    width: 100%;
    padding: 12px 8px !important;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }

  .navbar-nav .nav-item:last-child .nav-link {
    border-bottom: 0;
  }

  .nav-cta {
    display: inline-block;
    margin-top: 12px;
    width: 100%;
    text-align: center;
  }
}
