/*
====================================
Three Monkeys Communication (3MC)
Base Stylesheet

Version format = MAJOR.MINOR.PATCH
MAJOR = breaking changes (redesigns, incompatible updates)
MINOR = new features that don’t break existing behavior
PATCH = bug fixes and small safe improvements

Current Version: 1.1.1
====================================
*/

/* ================================
   THEME TOKENS
================================ */
:root {
  --brand: #0260A0;
  --text: #111;
  --muted: #555;
  --bg: #f3f5f7;
  --card: #fff;
  --border: #e1e5ea;
  --border-soft: #ededed;
  --soft-blue: #eef6ff;
}

/* ================================
   RESET / GLOBAL
================================ */
* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  line-height: 1.6;
  background: var(--bg);
  color: var(--text);
}

a {
  color: var(--brand);
  text-decoration: none;
}
a:hover,
a:focus { text-decoration: underline; }

/* Accessibility focus */
:focus-visible {
  outline: 3px solid var(--brand);
  outline-offset: 2px;
}

/* Global image safety */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Utility: visually hidden (SR-only) */
.visually-hidden {
  position: absolute !important;
  height: 1px;
  width: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

/* ================================
   LAYOUT HELPERS
================================ */
.container {
  width: min(100% - 2rem, 1000px);
  margin: 0 auto;
}

/* ================================
   SKIP LINK
================================ */
.skip-link {
  position: absolute;
  top: -40px;
  left: 1rem;
  background: var(--brand);
  color: #fff;
  padding: 0.5rem 0.75rem;
  border-radius: 0.4rem;
  font-weight: 600;
  z-index: 1000;
}
.skip-link:focus { top: 1rem; }

/* ================================
   HEADER / NAV / LOGO
================================ */
.site-header {
  background: var(--card);
  border-bottom: 2px solid var(--border);
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  color: var(--text);
}

/* Desktop logo size (phone is already okay per you) */
.brand img {
  height: 100px;
  width: auto;
  background: transparent;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
  justify-content: flex-end;
}

.site-nav a {
  padding: 0.4rem 0.65rem;
  border-radius: 0.45rem;
  font-size: 0.95rem;
}

.site-nav a:hover,
.site-nav a:focus {
  background: var(--soft-blue);
  text-decoration: none;
  outline: none;
}

.site-nav a.is-current,
.site-nav a[aria-current="page"] {
  background: var(--brand);
  color: #fff;
  font-weight: 600;
}

/* ================================
   HERO (PAGE TITLE AREA)
================================ */
.page-hero {
  text-align: center;
  padding: 1.6rem 0 1.2rem;
  border-bottom: 1px solid #eef1f4;
}

.page-hero h1 {
  margin: 0 0 0.4rem;
  font-size: clamp(1.8rem, 2.6vw, 2.6rem);
  line-height: 1.15;
}

.page-hero p {
  margin: 0;
  color: #333;
  font-size: clamp(1.05rem, 1.4vw, 1.25rem);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

/* Optional “hero with image” layout */
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2rem;
  align-items: center;
}

.hero-media img {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: #f8fafc;
  aspect-ratio: 16 / 9;
  object-fit: contain; /* prevents cut-off */
}

/* ================================
   BUTTONS (single source of truth)
================================ */
button, .button {
  display: inline-block;
  background: var(--brand);
  color: #fff;
  border: none;
  border-radius: 10px;
  padding: 0.65rem 1rem;
  font-size: 1rem;
  cursor: pointer;
}

button:hover,
button:focus,
.button:hover,
.button:focus {
  filter: brightness(0.95);
  outline: none;
}

.button-outline {
  background: transparent;
  color: var(--brand);
  border: 2px solid var(--brand);
}

.button-outline:hover,
.button-outline:focus {
  background: var(--soft-blue);
  filter: none;
}

.hero-cta {
  margin-top: 1.2rem;
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
}

/* ================================
   MAIN CONTENT WRAPPER + SECTIONS
================================ */
.site-main {
  background: var(--card);
  border: 1px solid #e6e6e6;
  border-radius: 16px;
  padding: 2.5rem 2rem;
  margin: 2rem auto;
}

.site-main section {
  background: var(--card);
  border: 1px solid var(--border-soft);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 1px 1px rgba(0,0,0,0.03);
}

.site-main h2 { margin-top: 0; }
.site-main ul { padding-left: 1.25rem; }
.site-main li { margin-bottom: 0.4rem; }

/* Shared grid patterns */
.intro-grid,
.content-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2rem;
  align-items: center;
}

/* Shared media blocks (NOT team) */
.intro-photo img,
.content-media img,
.award-card img {
  width: 100%;
  border-radius: 14px;
  border: 1px solid var(--border);
  background: #f8fafc;
  object-fit: contain; /* safe default */
}

/* Consistent placeholder aspect ratios */
.intro-photo img { aspect-ratio: 1 / 1; }
.content-media img,
.award-card img { aspect-ratio: 4 / 3; }

/* ================================
   CTA SECTION
================================ */
.cta {
  text-align: center;
}

.cta-buttons {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  justify-content: center;
  margin: 1rem 0 0.5rem;
}

.cta-note {
  margin: 0.5rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* ================================
   NOTE / CALLOUT
================================ */
.note {
  margin-top: 1rem;
  padding: 0.9rem 1rem;
  border-left: 4px solid var(--brand);
  background: var(--soft-blue);
  border-radius: 10px;
  color: #222;
}

/* ================================
   TEAM SECTION (CABINET STYLE)
================================ */
.team-section {
  max-width: 1000px;
  margin: 0 auto;
}

.team-intro {
  max-width: 720px;
  margin-bottom: 1.25rem;
}

/* 2x2 on desktop */
.team-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2rem;
  align-items: start;
}

.team-card {
  text-align: center;
  margin: 0;
}

.team-card img {
  width: 180px;
  height: 180px;
  object-fit: cover;      /* consistent “cabinet” crop */
  border-radius: 16px;    /* cabinet-style */
  margin: 0 auto;
  border: 1px solid var(--border);
  background: #f8fafc;
}

.team-card figcaption {
  margin-top: 0.35rem;
  line-height: 1.2;
}

.team-card figcaption strong {
  display: block;
  font-weight: 700;
  margin-bottom: 0.1rem; /* reduces name→title gap */
}

.team-card figcaption span {
  display: block;
  font-size: 0.88rem;
  color: var(--muted);
}

/* ================================
   CONTACT (overview + direct socials)
================================ */
.contact-overview {
  max-width: 720px;
}

.contact-overview p {
  margin-bottom: 0.9rem;
}

/* Contact form status box */
.form-status {
  margin: 0.75rem 0 0;
  padding: 0.9rem 1rem;
  border-left: 4px solid var(--brand);
  background: var(--soft-blue);
  border-radius: 10px;
  color: #222;
}
.form-status.is-error {
  border-left-color: #b42318;
  background: #fff1f0;
}

/* Direct contact social row */
.direct-contact-social {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
}

.direct-contact-social a {
  display: inline-flex;
  width: 34px;
  height: 34px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
}

.direct-contact-social a:hover,
.direct-contact-social a:focus {
  background: var(--soft-blue);
  outline: none;
}

.direct-contact-social img {
  width: 20px;
  height: 20px;
  opacity: 0.9;
}

.direct-contact-social a:hover img,
.direct-contact-social a:focus img {
  opacity: 1;
}

/* ================================
   FORMS (inputs)
================================ */
label { font-weight: 600; }

input, textarea, select, button {
  font: inherit;
}

input, textarea, select {
  width: 100%;
  max-width: 640px;
  padding: 0.6rem 0.75rem;
  border: 1px solid #cfcfcf;
  border-radius: 10px;
  background: #fff;
}

textarea { resize: vertical; }

fieldset {
  max-width: 640px;
  border: 1px solid #d9d9d9;
  border-radius: 12px;
  padding: 1rem;
  margin: 1rem 0;
}

legend {
  font-weight: 700;
  padding: 0 0.5rem;
}

input[type="checkbox"],
input[type="radio"] {
  width: auto;
  max-width: none;
}

/* ================================
   IMPACT: Award photos grid
================================ */
.award-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
  align-items: start;
}

.award-card {
  margin: 0;
  background: #fff;
}

.award-card img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: #f8fafc;
}

.award-card figcaption {
  margin-top: 0.35rem;
  font-size: 0.85rem;
  color: var(--muted);
  text-align: center;
}

/* ================================
   FOOTER
================================ */
.site-footer {
  background: var(--card);
  border-top: 2px solid var(--border);
  margin-top: 2.5rem;
  padding: 1.75rem 0;
}

.footer-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.9rem;
  text-align: center;
}

.footer-social {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: center;
}

.footer-social a {
  display: inline-flex;
  width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
}

.footer-social a:hover,
.footer-social a:focus {
  background: var(--soft-blue);
  outline: none;
}

.footer-social img {
  width: 22px;
  height: 22px;
  opacity: 0.9;
}

.footer-social a:hover img,
.footer-social a:focus { opacity: 1; }

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.footer-nav a {
  padding: 0.35rem 0.6rem;
  border-radius: 0.4rem;
  font-size: 0.9rem;
}

.footer-nav a:hover,
.footer-nav a:focus {
  background: var(--soft-blue);
  text-decoration: none;
  outline: none;
}

.footer-copy {
  margin: 0;
  font-size: 0.9rem;
  color: var(--muted);
}

.site-version {
  margin: 0;
  font-size: 0.85rem;
  color: #667;
}

/* ================================
   COOKIE BANNER
================================ */
.cookie-banner {
  position: fixed;
  left: 1rem;
  right: 1rem;
  bottom: 1rem;
  z-index: 9999;
  background: var(--card);
  border: 1px solid #e6e6e6;
  border-radius: 14px;
  box-shadow: 0 6px 24px rgba(0,0,0,0.12);
  padding: 1rem;
}

.cookie-inner {
  max-width: 1000px;
  margin: 0 auto;
  display: grid;
  gap: 0.75rem;
}

.cookie-text {
  margin: 0;
  color: #222;
}

.cookie-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.cookie-actions .button { margin: 0; }

/* ================================
   RESPONSIVE
================================ */
@media (max-width: 700px) {
  .topbar {
    flex-direction: column;
    align-items: center;
  }

  .site-nav { justify-content: center; }

  .hero-grid,
  .intro-grid,
  .content-grid {
    grid-template-columns: 1fr;
    gap: 1.25rem;
  }

  .site-main {
    padding: 1.75rem 1.25rem;
    margin: 1.5rem auto;
  }

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

  .team-card img {
    width: 160px;
    height: 160px;
  }

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