/* ============================================================
   IOA – Irish Orthopaedic Association
   Main Stylesheet
   ============================================================ */

/* ── CSS Variables ── */
:root {
  --teal-900: #0d3d38;
  --teal-800: #115049;
  --teal-700: #14665c;
  --teal-600: #1a8070;
  --teal-500: #209a86;
  --teal-400: #3db5a0;
  --teal-300: #6dcbba;
  --teal-200: #a4ddd4;
  --teal-100: #d2eeeb;
  --teal-50:  #edf8f6;

  --slate:    #344048;
  --gold:     #c9a227;
  --gold-bg:  #fdf8e7;
  --gold-b:   #f0d98a;

  --txt:      #1a2428;
  --txt2:     #4a5a60;
  --txt3:     #6b7a80;

  --border:   #dde8e5;
  --border-l: #e0eceb;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 12px;

  --shadow-sm: 0 1px 4px rgba(0,0,0,.06);
  --shadow-md: 0 2px 12px rgba(32,154,134,.1);

  --font: 'Segoe UI', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', Arial, sans-serif;
}

/* ── Reset & Base ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.6;
  color: var(--txt);
  background: #f7f8f8;
}

img { max-width: 100%; height: auto; display: block; }
a  { text-decoration: none; color: inherit; }
ul { list-style: none; }
button { font-family: inherit; cursor: pointer; }

/* ── Layout Wrapper ── */
.wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 32px;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 22px;
  border-radius: var(--radius-md);
  font-size: 14px;
  font-weight: 500;
  border: none;
  cursor: pointer;
  white-space: nowrap;
  transition: background .18s, color .18s, border-color .18s;
}

.btn-primary {
  background: var(--teal-400);
  color: #fff;
}
.btn-primary:hover { background: var(--teal-300); color: var(--teal-900); }

.btn-outline-white {
  background: transparent;
  color: #fff;
  border: 1.5px solid rgba(255,255,255,.4);
}
.btn-outline-white:hover { background: rgba(255,255,255,.1); }

.btn-outline-teal {
  background: #fff;
  color: var(--teal-700);
  border: 1.5px solid var(--teal-400);
}
.btn-outline-teal:hover { background: var(--teal-50); }

.btn-teal {
  background: var(--teal-500);
  color: #fff;
}
.btn-teal:hover { background: var(--teal-600); }

.btn-sm {
  padding: 8px 16px;
  font-size: 13px;
}

/* ── Tags / Badges ── */
.tag {
  display: inline-block;
  font-size: 11px;
  font-weight: 500;
  padding: 3px 10px;
  border-radius: 20px;
}
.tag-teal  { background: var(--teal-50);  color: var(--teal-700); border: 1px solid var(--teal-100); }
.tag-gold  { background: var(--gold-bg);  color: #7a5f0a;         border: 1px solid var(--gold-b); }
.tag-slate { background: #f0f3f4;         color: var(--slate);    border: 1px solid #cdd4da; }

/* ── Section Helpers ── */
.sec-over {
  font-size: 11px;
  font-weight: 600;
  color: var(--teal-500);
  text-transform: uppercase;
  letter-spacing: .8px;
  margin-bottom: 6px;
}
.sec-title {
  font-size: 22px;
  font-weight: 600;
  color: var(--txt);
}
.sec-title span { color: var(--teal-700); }

.sec-hdr {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  margin-bottom: 28px;
}
.sec-link {
  font-size: 13px;
  font-weight: 500;
  color: var(--teal-600);
  display: flex;
  align-items: center;
  gap: 5px;
  transition: color .15s;
}
.sec-link:hover { color: var(--teal-800); }
.sec-link i { font-size: 13px; }

.divider { height: 1px; background: var(--border-l); }

/* ============================================================
   TOP BAR
   ============================================================ */
.topbar { background: var(--teal-900); }
.topbar .wrap {
  height: 34px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.topbar-left {
  color: rgba(255,255,255,.55);
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 6px;
}
.topbar-left i { color: var(--teal-300); font-size: 13px; }
.topbar-right { display: flex; gap: 14px; align-items: center; }
.topbar-right a {
  color: rgba(255,255,255,.65);
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color .15s;
}
.topbar-right a:hover { color: #fff; }
.topbar-sep { color: rgba(255,255,255,.2); }

/* ============================================================
   HEADER / NAV
   ============================================================ */
.site-header {
  background: #fff;
  border-bottom: 2px solid var(--teal-100);
  position: sticky;
  top: 0;
  z-index: 1000;
  box-shadow: 0 1px 8px rgba(0,0,0,.06);
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 74px;
  gap: 16px;
}

/* Brand */
.nav-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
  text-decoration: none;
}
.nav-logo {
  width: 54px;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.nav-logo img { width: 100%; height: 100%; object-fit: contain; }
.brand-text { display: flex; flex-direction: column; gap: 2px; }
.brand-name {
  color: var(--teal-800);
  font-size: 15px;
  font-weight: 600;
  white-space: nowrap;
  line-height: 1.2;
}
.brand-sub {
  color: var(--txt3);
  font-size: 11px;
  white-space: nowrap;
}

/* Nav links */
.nav-links {
  display: flex;
  align-items: center;
  flex: 1;
  justify-content: center;
  gap: 0;
}
.nav-links a {
  color: var(--txt2);
  font-size: 13px;
  font-weight: 500;
  padding: 0 12px;
  height: 74px;
  display: flex;
  align-items: center;
  border-bottom: 2.5px solid transparent;
  white-space: nowrap;
  margin-bottom: -2px;
  transition: color .15s, border-color .15s;
}
.nav-links a:hover  { color: var(--teal-700); }
.nav-links a.active { color: var(--teal-600); border-bottom-color: var(--teal-500); }

/* Nav actions */
.nav-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }

/* Hamburger (mobile) */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
  color: var(--txt);
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--teal-700);
  margin: 5px 0;
  border-radius: 2px;
  transition: transform .25s, opacity .25s;
}

/* Teal accent rule under header */
.header-rule {
  height: 3px;
  background: linear-gradient(90deg, var(--teal-500), var(--teal-300), transparent);
}

/* ============================================================
   HERO
   ============================================================ */
.hero {
  background: linear-gradient(145deg, var(--teal-900) 0%, var(--teal-800) 55%, var(--teal-700) 100%);
  position: relative;
  overflow: hidden;
}
.hero-bg-pattern {
  position: absolute;
  inset: 0;
  opacity: .03;
  background-image: radial-gradient(circle, #fff 1px, transparent 1px);
  background-size: 24px 24px;
  pointer-events: none;
}
/* Decorative SVG overlay */
.hero-overlay {
  position: absolute;
  right: 0;
  top: 0;
  width: 45%;
  height: 100%;
  opacity: .04;
  pointer-events: none;
}

.hero .wrap {
  position: relative;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 48px;
  align-items: center;
  padding-top: 56px;
  padding-bottom: 52px;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: rgba(61,181,160,.18);
  border: 1px solid rgba(61,181,160,.3);
  color: var(--teal-200);
  font-size: 12px;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 18px;
}
.hero-eyebrow i { font-size: 14px; }

.hero-title {
  color: #fff;
  font-size: 36px;
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 16px;
}
.hero-title em { color: var(--teal-300); font-style: normal; }

.hero-sub {
  color: rgba(255,255,255,.68);
  font-size: 15px;
  line-height: 1.8;
  margin-bottom: 28px;
  max-width: 520px;
}

.hero-btns { display: flex; gap: 14px; flex-wrap: wrap; }

/* Stats grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
}
.stat-card {
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: var(--radius-lg);
  padding: 18px 12px;
  text-align: center;
  transition: background .18s;
}
.stat-card:hover { background: rgba(255,255,255,.11); }
.stat-number {
  color: var(--teal-300);
  font-size: 26px;
  font-weight: 700;
  line-height: 1;
}
.stat-number sup { font-size: 15px; }
.stat-label {
  color: rgba(255,255,255,.52);
  font-size: 11px;
  margin-top: 6px;
}

/* ============================================================
   NOTICE BAR
   ============================================================ */
.notice-bar { background: var(--teal-50); border-bottom: 1px solid var(--teal-100); }
.notice-bar .wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 10px;
  padding-bottom: 10px;
}
.notice-badge {
  background: var(--teal-600);
  color: #fff;
  font-size: 10.5px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  white-space: nowrap;
  flex-shrink: 0;
}
.notice-text {
  font-size: 13px;
  color: var(--teal-900);
  flex: 1;
}
.notice-link {
  font-size: 13px;
  font-weight: 600;
  color: var(--teal-600);
  display: flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
  transition: color .15s;
}
.notice-link:hover { color: var(--teal-800); }

/* ============================================================
   EVENTS SECTION
   ============================================================ */
.section-white { background: #fff; }
.section-tint  { background: var(--teal-50); }

.section-white .wrap,
.section-tint .wrap {
  padding-top: 52px;
  padding-bottom: 52px;
}

.events-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.event-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color .18s, box-shadow .18s;
}
.event-card:hover {
  border-color: var(--teal-400);
  box-shadow: var(--shadow-md);
}

.event-card-body {
  padding: 20px;
  border-left: 4px solid var(--teal-500);
}
.event-card-body.gold  { border-left-color: var(--gold); }
.event-card-body.slate { border-left-color: var(--slate); }

.event-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--txt3);
  margin-bottom: 8px;
}
.event-meta i { font-size: 13px; color: var(--teal-500); }
.event-meta.gold  i { color: var(--gold); }
.event-meta.slate i { color: var(--slate); }

.event-title {
  font-size: 15px;
  font-weight: 600;
  color: var(--txt);
  line-height: 1.4;
  margin-bottom: 8px;
}
.event-location {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 12.5px;
  color: var(--txt2);
  margin-bottom: 14px;
}
.event-location i { font-size: 12px; color: var(--teal-500); }
.event-location.gold  i { color: var(--gold); }
.event-location.slate i { color: var(--slate); }

.event-tags { display: flex; gap: 6px; flex-wrap: wrap; }

/* ============================================================
   NEWS SECTION
   ============================================================ */
.news-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 20px;
}

/* Featured article */
.news-featured {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  transition: border-color .18s;
}
.news-featured:hover { border-color: var(--teal-400); }

.news-featured-img {
  height: 200px;
  background: linear-gradient(135deg, var(--teal-900), var(--teal-700));
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.news-featured-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: .85;
}
.news-featured-img .placeholder-icon {
  font-size: 64px;
  color: rgba(255,255,255,.15);
}
.news-img-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  background: var(--teal-500);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
}

.news-featured-body { padding: 22px; }
.news-category {
  font-size: 11px;
  font-weight: 600;
  color: var(--teal-600);
  text-transform: uppercase;
  letter-spacing: .6px;
  margin-bottom: 8px;
}
.news-featured-title {
  font-size: 18px;
  font-weight: 600;
  color: var(--txt);
  line-height: 1.4;
  margin-bottom: 10px;
}
.news-excerpt {
  font-size: 13.5px;
  color: var(--txt2);
  line-height: 1.7;
}
.news-date {
  font-size: 12px;
  color: var(--txt3);
  margin-top: 12px;
  display: flex;
  align-items: center;
  gap: 5px;
}

/* News sidebar list */
.news-sidebar { display: flex; flex-direction: column; gap: 12px; }

.news-item {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  transition: border-color .18s;
}
.news-item:hover { border-color: var(--teal-300); }

.news-item-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--teal-400);
  margin-top: 5px;
  flex-shrink: 0;
}

.news-item-cat {
  font-size: 10px;
  font-weight: 600;
  color: var(--teal-600);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-bottom: 3px;
}
.news-item-title {
  font-size: 13px;
  font-weight: 600;
  color: var(--txt);
  line-height: 1.45;
  margin-bottom: 5px;
}
.news-item-date {
  font-size: 11px;
  color: var(--txt3);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* ============================================================
   QUICK LINKS
   ============================================================ */
.quick-links-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.quick-card {
  background: #fff;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 14px;
  text-align: center;
  transition: border-color .18s, background .18s;
  text-decoration: none;
  display: block;
}
.quick-card:hover {
  border-color: var(--teal-400);
  background: var(--teal-50);
}

.quick-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--teal-50);
  border: 1px solid var(--teal-100);
  margin: 0 auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .18s;
}
.quick-icon i { font-size: 22px; color: var(--teal-600); }
.quick-card:hover .quick-icon { background: var(--teal-100); }

.quick-label {
  font-size: 12.5px;
  font-weight: 500;
  color: var(--txt2);
  line-height: 1.3;
}

/* ============================================================
   CORPORATE PARTNERS
   ============================================================ */
.partners-bar {
  background: #fff;
  border-top: 1px solid var(--border-l);
  border-bottom: 1px solid var(--border-l);
}
.partners-bar .wrap {
  display: flex;
  align-items: center;
  gap: 24px;
  padding-top: 22px;
  padding-bottom: 22px;
}
.partners-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--txt3);
  text-transform: uppercase;
  letter-spacing: .7px;
  white-space: nowrap;
  padding-right: 20px;
  border-right: 1px solid var(--border);
}
.partners-list { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.partner-chip {
  background: #f2f8f7;
  border: 1px solid var(--teal-100);
  border-radius: var(--radius-sm);
  padding: 7px 18px;
  font-size: 12px;
  font-weight: 500;
  color: var(--teal-700);
  transition: background .15s, border-color .15s;
}
.partner-chip:hover { background: var(--teal-50); border-color: var(--teal-200); }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: var(--teal-900); }
.site-footer .wrap { padding-top: 48px; padding-bottom: 20px; }

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 36px;
}

.footer-brand { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 14px; }
.footer-logo {
  width: 44px;
  height: 52px;
  background: rgba(255,255,255,.1);
  border-radius: var(--radius-sm);
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.footer-logo img { width: 100%; height: 100%; object-fit: contain; }
.footer-brand-name { color: #fff; font-size: 14px; font-weight: 600; margin-bottom: 3px; }
.footer-brand-sub  { color: rgba(255,255,255,.42); font-size: 11px; }
.footer-about      { color: rgba(255,255,255,.42); font-size: 12.5px; line-height: 1.75; }

.footer-col-title {
  color: rgba(255,255,255,.48);
  font-size: 10.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .7px;
  margin-bottom: 14px;
}
.footer-links { display: flex; flex-direction: column; gap: 9px; }
.footer-links a {
  color: rgba(255,255,255,.4);
  font-size: 13px;
  transition: color .15s;
}
.footer-links a:hover { color: rgba(255,255,255,.88); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding-top: 18px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.footer-copy { color: rgba(255,255,255,.28); font-size: 12px; }

.footer-social { display: flex; gap: 10px; }
.footer-social a {
  width: 34px;
  height: 34px;
  background: rgba(255,255,255,.07);
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255,255,255,.4);
  font-size: 16px;
  transition: background .15s, color .15s;
}
.footer-social a:hover { background: var(--teal-600); color: #fff; }

/* ============================================================
   RESPONSIVE
   ============================================================ */

/* Large tablets → 1024px */
@media (max-width: 1024px) {
  .wrap { padding: 0 24px; }

  .nav-links a { padding: 0 9px; font-size: 12.5px; }
  .brand-name  { font-size: 14px; }

  .hero .wrap  { grid-template-columns: 1fr 1fr; gap: 32px; }
  .hero-title  { font-size: 30px; }

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

  .footer-grid { grid-template-columns: 1.5fr 1fr 1fr; gap: 28px; }
  .footer-grid .footer-col:last-child { display: none; }

  .quick-links-grid { grid-template-columns: repeat(3, 1fr); }
}

/* Tablets → 768px */
@media (max-width: 768px) {
  .wrap { padding: 0 18px; }

  /* Topbar — hide left info, keep social */
  .topbar-left  { display: none; }
  .topbar-right a span { display: none; }

  /* Header */
  .site-header .wrap { height: 64px; }
  .nav-logo  { width: 44px; height: 50px; }
  .brand-name  { font-size: 13.5px; }
  .brand-sub   { display: none; }

  /* Hide nav links, show hamburger */
  .nav-links   { display: none; position: absolute; top: 64px; left: 0; right: 0; background: #fff; flex-direction: column; border-top: 1px solid var(--teal-100); box-shadow: 0 4px 20px rgba(0,0,0,.1); z-index: 999; }
  .nav-links.open { display: flex; }
  .nav-links a { height: auto; padding: 14px 24px; border-bottom: 1px solid #f0f4f3; border-left: none; margin: 0; font-size: 14px; }
  .nav-links a.active { border-left: 3px solid var(--teal-500); background: var(--teal-50); }
  .nav-toggle  { display: block; }
  .nav-actions .btn-outline-teal { display: none; }

  /* Hero */
  .hero .wrap  { grid-template-columns: 1fr; padding-top: 40px; padding-bottom: 36px; gap: 32px; }
  .hero-title  { font-size: 26px; }
  .hero-sub    { font-size: 14px; }
  .stats-grid  { grid-template-columns: repeat(3, 1fr); }
  .stat-number { font-size: 20px; }

  /* Notice */
  .notice-text  { font-size: 12px; }
  .notice-link  { display: none; }

  /* Events */
  .events-grid  { grid-template-columns: 1fr; }

  /* News */
  .news-grid    { grid-template-columns: 1fr; }

  /* Quick links */
  .quick-links-grid { grid-template-columns: repeat(3, 1fr); }

  /* Partners */
  .partners-bar .wrap { flex-direction: column; align-items: flex-start; gap: 12px; }
  .partners-label     { border-right: none; padding-right: 0; }

  /* Footer */
  .footer-grid   { grid-template-columns: 1fr 1fr; gap: 28px; }
  .footer-bottom { flex-direction: column; gap: 14px; text-align: center; }

  /* Sections */
  .section-white .wrap,
  .section-tint  .wrap { padding-top: 36px; padding-bottom: 36px; }

  .sec-hdr       { flex-direction: column; align-items: flex-start; gap: 10px; }
  .sec-title     { font-size: 20px; }
}

/* Mobile → 480px */
@media (max-width: 480px) {
  .wrap { padding: 0 14px; }

  .hero-title  { font-size: 22px; }
  .hero-btns   { flex-direction: column; }
  .hero-btns .btn { width: 100%; justify-content: center; }
  .stats-grid  { grid-template-columns: repeat(2, 1fr); }

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

  .footer-grid { grid-template-columns: 1fr; }

  .nav-actions { gap: 6px; }
  .btn-sm      { padding: 7px 12px; font-size: 12px; }
}
