/* info.css - User-Facing Event Information Page */

/* ============================================
   BASE STYLES (Mobile First - 320px+)
   ============================================ */

/* Container */
.container {
  max-width: 100%;
  padding: 0 1rem;
  margin: 0 auto;
}

.my-4 {
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
}

/* Page Title */
.container > h1 {
  font-size: 1.75rem;
  font-weight: 700;
  color: #000;
  margin: 1.5rem 0 2rem 0;
  line-height: 1.2;
}

/* Section Headings */
section h2 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #000;
  margin: 0 0 1rem 0;
  padding-bottom: 0.5rem;
  display: inline-block;
}

section h3 {
  font-size: 1.125rem;
  font-weight: 600;
  color: #000;
  margin: 0;
}

/* Section Spacing */
section {
  margin-bottom: 3rem;
  padding-bottom: 2rem;
}

section:last-child {
  border-bottom: none;
}

/* Paragraphs */
section p {
  color: #374151;
  line-height: 1.6;
  font-size: 1rem;
  margin-bottom: 1rem;
}

/* Images */
.img-fluid {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Row/Grid Layout */
.row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin: 1.5rem 0;
}

.col-12,
.col-md-5,
.col-md-6,
.col-md-7 {
  width: 100%;
}

/* =========================================
   INFO – Split card (UPDATED for your new HTML)
   - Directions uses .info-split__media (square) inside .info-split__content
   - Parking uses .info-split__sub (left) + text (middle) + .info-split__media (right) on desktop
   ========================================= */

.info-split {
  margin: 2rem 0 3rem;
}

/* wrapper controls overall width + centering */
.info-split__wrap {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1rem;
}

/* panel */
.info-split__panel {
  border-radius: 16px;
  min-height: clamp(200px, 20vw, 260px);
  padding: clamp(18px, 2.4vw, 4px) clamp(18px, 3vw, 4px);
  position: relative;
}

/* title */
.info-split__title {
  margin: 0 0 12px 0;
  font-size: clamp(28px, 4.2vw, 44px);
  font-weight: 900;
  line-height: 1.05;
  letter-spacing: -0.02em;
}

/* body */
.info-split__body p {
  margin: 0 0 10px 0;
  max-width: 52ch;
}

/* links row */
.info-split__links {
  margin-top: 10px;
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
}

.info-split__links a {
  font-weight: 800;
  text-decoration: none;
}

.info-split__links a:hover {
  text-decoration: underline;
}

/* sub image */
.info-split__sub {
  flex: 0 0 auto;
  width: clamp(86px, 10vw, 140px);
  height: clamp(86px, 10vw, 140px);
  display: grid;
  place-items: center;
  opacity: 0.95;
}

.info-split__sub img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

/* square main image (Directions + Parking) */
.info-split__media {
  width: min(280px, 100%);
  aspect-ratio: 1 / 1;
  border-radius: 12px;
  overflow: hidden;
  margin: 0; /* spacing handled by layout gaps */
}

.info-split__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* content wrapper now used in BOTH sections */
.info-split__content {
  min-width: 0;
}

/* only exists when you wrap text in this div (Directions + Parking) */
.info-split__text {
  min-width: 0;
}

/* ---------- BLUE (Directions) ---------- */
.info-split--blue .info-split__panel {
  background: #ffffff;
  border: 1px solid #000000;
}

.info-split--blue .info-split__title {
}

.info-split--blue .info-split__body p {
}

.info-split--blue .info-split__links a {
}

/* ---------- YELLOW (Parking) ---------- */
.info-split--yellow .info-split__panel {
  background: #ffffff;
  border: 1px solid #000000;
}

.info-split--yellow .info-split__title {
}

.info-split--yellow .info-split__body p {
}

.info-split--yellow .info-split__links a {
  font-weight: 800;
  text-decoration: none;
}

.info-split--yellow .info-split__links a:hover {
  text-decoration: underline;
}

/* ============================================
   UPDATED RESPONSIVE: split sections stack + center on small screens
   (this fixes the missing small-screen styling you flagged)
   ============================================ */
@media (max-width: 1023px) {
  .info-split__panel {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1.25rem;
    text-align: center;
  }

  .info-split__content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
  }

  .info-split__text {
    max-width: 42rem;
    margin: 0 auto;
  }

  .info-split__links {
    justify-content: center;
  }

  .info-split__media,
  .info-split__sub {
    margin: 0 auto;
  }

  .info-split__media {
    float: none !important; /* kill any old float if present */
  }

  .info-split__sub {
    width: 92px;
    height: 92px;
  }
}

/* ============================================
   UPDATED DESKTOP: explicit order per section
   - Directions: main (left) | text (middle) | sub (right)
   - Parking:    sub (left)  | text (middle) | main (right)
   ============================================ */
@media (min-width: 1024px) {
  /* shared: 3-column row */
  #directions .info-split__panel,
  #parking .info-split__panel {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    column-gap: clamp(18px, 3vw, 44px);
  }

  /* Make inner wrapper not interfere with the panel grid */
  #directions .info-split__content,
  #parking .info-split__content {
    display: contents;
  }

  /* DIRECTIONS layout */
  #directions .info-split__media {
    grid-column: 1;
    grid-row: 1;
    width: 320px;
    justify-self: start;
  }

  #directions .info-split__text {
    grid-column: 2;
    grid-row: 1;
    text-align: left;
  }

  #directions .info-split__sub {
    grid-column: 3;
    grid-row: 1;
    justify-self: end;
  }

  /* PARKING layout */
  #parking .info-split__sub {
    grid-column: 1;
    grid-row: 1;
    justify-self: start;
    margin: 0;
  }

  #parking .info-split__text {
    grid-column: 2;
    grid-row: 1;
    text-align: left;
  }

  #parking .info-split__media {
    grid-column: 3;
    grid-row: 1;
    width: 320px;
    justify-self: end;
  }

  /* Links left-aligned on desktop */
  #directions .info-split__links,
  #parking .info-split__links {
    justify-content: flex-start;
  }
}

/* ============================================
   SMALL TABLET (600px+)
   ============================================ */
@media (min-width: 600px) {
  .container {
    padding: 0 1.5rem;
  }

  .container > h1 {
    font-size: 2rem;
    margin: 2rem 0 2.5rem 0;
  }

  section h2 {
    font-size: 1.75rem;
  }

  .row {
    gap: 2rem;
  }

  /* 2 column grid for accommodation */
  .row .col-md-6 {
    grid-column: span 1;
  }

  .row {
    grid-template-columns: repeat(2, 1fr);
  }

  .card-img-top {
    height: 220px;
  }

  .card-body {
    padding: 1.75rem;
  }
}

/* ============================================
   Accommodation Cards
   ============================================ */

.card-row {
  margin: 0 auto;
}

.inner-row {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
}
.card {
  background: #fff;
  border: 2px solid #e5e7eb;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  height: 100%;
  width: 100%;
  display: flex;
  flex-direction: column;
  padding: 0 1rem;
}

.card:hover {
  border-color: #ffcc37;
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(74, 222, 128, 0.15);
}

.card-img-top {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-bottom: 2px solid #e5e7eb;
}

.card-body {
  padding: 1.5rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.con-header {
  text-align: center;
}

.card-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #000;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.card-text {
  color: #374151;
  line-height: 1.6;
  margin-bottom: 0.75rem;
  font-size: 0.9375rem;
}

.card-text:last-child {
  margin-bottom: 0;
}

.card-text strong {
  color: #000;
  font-weight: 600;
}

.card-text a {
  color: #ffcc37;
  text-decoration: none;
  font-weight: 600;
  transition: color 0.2s ease;
}

.card-text a:hover {
  color: #f6d36b;
  text-decoration: underline;
}

/* Badge */
.badge {
  display: inline-block;
  padding: 0.25rem 0.625rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.bg-success {
  background: #dcfce7;
  color: #166534;
}

/* ============================================
   BUTTON LINKS (Make buttons look like regular links)
   ============================================ */
.btn,
.btn-outline-primary,
.btn-outline-secondary,
.btn-sm {
  display: inline;
  padding: 0;
  font-size: inherit;
  font-weight: 600;
  text-decoration: none;
  border-radius: 0;
  transition: color 0.2s ease;
  cursor: pointer;
  border: none;
  background: none;
  color: #ffcc37;
  min-height: auto;
}

.btn:hover,
.btn-outline-primary:hover,
.btn-outline-secondary:hover {
  color: #22c55e;
  text-decoration: underline;
  transform: none;
  box-shadow: none;
  background: none;
  border: none;
}

.btn:focus {
  outline: 2px solid #4ade80;
  outline-offset: 2px;
  border-radius: 2px;
}

/* Utility Classes */
.mt-3 {
  margin-top: 1rem;
}

.mb-3 {
  margin-bottom: 1rem;
}

.ms-2 {
  margin-left: 0.5rem;
}

/* Link external icon */
.btn[target="_blank"]::after,
a[target="_blank"]::after {
  content: " ↗";
  font-size: 0.875em;
  opacity: 0.7;
}

/* ============================================
   TABLET (768px+)
   ============================================ */
@media (min-width: 768px) {
  .container {
    max-width: 1200px;
    padding: 0 2rem;
  }

  .container > h1 {
    font-size: 2.5rem;
    margin: 2.5rem 0 3rem 0;
  }

  section h2 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
  }

  /* Legacy directions row rules (kept; harmless if unused) */
  #directions .row {
    grid-template-columns: 5fr 7fr;
    align-items: start;
  }

  #directions .col-md-5 {
    grid-column: 1;
  }

  #directions .col-md-7 {
    grid-column: 2;
  }

  .card-img-top {
    height: 240px;
  }

  .accordion-button {
    font-size: 1.0625rem;
    padding: 1.25rem 1.5rem;
  }

  .accordion-body {
    padding: 1.25rem 1.5rem 1.75rem;
  }
}

/* ============================================
   DESKTOP (1024px+)
   ============================================ */
@media (min-width: 1024px) {
  .container > h1 {
    font-size: 3rem;
  }

  section h2 {
    font-size: 2.25rem;
  }

  section h3 {
    font-size: 1.25rem;
  }

  .my-4 {
    margin-top: 2rem;
    margin-bottom: 2rem;
  }

  .card-img-top {
    height: 260px;
  }

  .card-body {
    padding: 2rem;
  }

  .card-title {
    font-size: 1.375rem;
  }
}

/* ============================================
   LARGE DESKTOP (1280px+)
   ============================================ */
@media (min-width: 1280px) {
  .container {
    max-width: 1280px;
  }
}

/* ============================================
   ACCESSIBILITY & ENHANCEMENTS
   ============================================ */

/* Accordion (FAQ) */
.accordion {
  border-radius: 12px;
  overflow: hidden;
  border: 2px solid #e5e7eb;
}

.accordion-item {
  border: none;
  border-bottom: 1px solid #e5e7eb;
}

.accordion-item:last-child {
  border-bottom: none;
}

.accordion-header {
  margin: 0;
}

.accordion-button {
  background: #fff;
  color: #000;
  font-weight: 600;
  font-size: 1rem;
  padding: 1rem 1.25rem;
  border: none;
  width: 100%;
  text-align: left;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}

.accordion-button::after {
  content: "+";
  font-size: 1.5rem;
  font-weight: 400;
  color: #4ade80;
  transition: transform 0.2s ease;
  flex-shrink: 0;
  margin-left: 1rem;
}

.accordion-button:not(.collapsed) {
  background: #f0fdf4;
  color: #000;
}

.accordion-button:not(.collapsed)::after {
  content: "−";
  transform: rotate(0deg);
}

.accordion-button:hover {
  background: #f9fafb;
}

.accordion-button:focus {
  outline: 2px solid #ffcc37;
  outline-offset: -2px;
  box-shadow: none;
}

.accordion-collapse {
  transition: all 0.3s ease;
}

.accordion-body {
  padding: 1rem 1.25rem 1.5rem;
  background: #fff;
  color: #374151;
  line-height: 1.6;
}

/* Focus states */
.accordion-button:focus-visible {
  outline: 2px solid #ffcc37;
  outline-offset: 2px;
}

.card-text a:focus-visible {
  outline: 2px solid #fcd560;
  outline-offset: 2px;
  border-radius: 2px;
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
  .card,
  .accordion-button,
  .accordion-button::after,
  .accordion-collapse {
    transition: none;
  }

  .card:hover {
    transform: none;
  }
}

/* Dark mode support */
@media (prefers-color-scheme: dark) {
  .container > h1,
  section h2,
  section h3 {
    color: #fff;
  }

  section {
    border-bottom-color: #3a3a3a;
  }

  section p,
  .card-text {
    color: #d1d5db;
  }

  .card-text strong {
    color: #fff;
  }

  .card {
    background: #1a1a1a;
    border-color: #3a3a3a;
  }

  .card:hover {
    background: #1f1f1f;
  }

  .card-img-top {
    border-bottom-color: #3a3a3a;
  }

  .card-title {
    color: #fff;
  }

  .card-text a {
    color: #ffcc37;
  }

  .card-text a:hover {
    color: #fad974;
  }

  .bg-success {
    background: #14532d;
    color: #86efac;
  }

  .accordion {
    border-color: #3a3a3a;
  }

  .accordion-item {
    border-bottom-color: #3a3a3a;
  }

  .accordion-button {
    background: #1a1a1a;
    color: #fff;
  }

  .accordion-button:not(.collapsed) {
    background: #1e3a1a;
  }

  .accordion-button:hover {
    background: #2a2a2a;
  }

  .accordion-body {
    background: #1a1a1a;
    color: #d1d5db;
  }

  /* Keep split card readable in dark mode too */
  .info-split--yellow .info-split__panel {
    background: #ffde59;
    color: #000;
  }

  .info-split--blue .info-split__panel {
    background: #0cc0df;
    color: #fff;
  }
}

/* Print styles */
@media print {
  .container {
    max-width: 100%;
    padding: 0;
  }

  .card {
    break-inside: avoid;
    border: 1px solid #000;
    box-shadow: none;
  }

  .card:hover {
    transform: none;
    box-shadow: none;
  }

  .accordion-button {
    background: transparent;
  }

  .accordion-button::after {
    display: none;
  }

  .accordion-collapse {
    display: block !important;
  }
}

/* Link external icon (optional) */
.card-text a[target="_blank"]::after {
  content: " ↗";
  font-size: 0.875em;
  opacity: 0.7;
}
