/* ============================================================
   NEW ROOTS MONTESSORI — Main Stylesheet
   Brand colours: Plantation #2C554D · Battleship #8D957E
   Orchid #DF8992 · Serria #DB904D · Slate #77888F
   White Rock #F0EADE · White #FFFFFF
   ============================================================ */

/* ---- Tokens ---- */
:root {
  --plantation: #2C554D;
  --battleship:  #8D957E;
  --orchid:      #DF8992;
  --whiterock:   #F0EADE;
  --slate:       #77888F;
  --serria:      #DB904D;
  --white:       #FFFFFF;

  --text:        #1d1d1d;
  --text-mid:    #484848;
  --text-light:  #77888F;

  --font-display: 'Kenarose', 'Arial Black', Arial, sans-serif;
  --font-body:    'Rethink Sans', Arial, sans-serif;

  --radius-sm:   8px;
  --radius-md:   14px;
  --radius-lg:   24px;
  --radius-pill: 999px;

  --shadow-sm:   0 2px 8px  rgba(0,0,0,.07);
  --shadow-md:   0 6px 20px rgba(44,85,77,.13);
  --shadow-lg:   0 16px 40px rgba(44,85,77,.18);

  --max-w:       1100px;
  --section-y:   clamp(3.5rem, 8vw, 6rem);
  --gap:         clamp(1rem, 2.5vw, 1.75rem);
  --t:           .22s ease;
}

@font-face {
  font-family: 'Kenarose';
  src: url('../assets/Kenarose.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html  { scroll-behavior: smooth; font-size: 16px; }
body  { font-family: var(--font-body); color: var(--text); background: var(--white); line-height: 1.65; overflow-x: hidden; }
img   { max-width: 100%; height: auto; display: block; }
a     { color: inherit; text-decoration: none; }
ul    { list-style: none; }
input, textarea, select, button { font: inherit; }

/* ---- Typography ---- */
h1 { font-family: var(--font-display); font-size: clamp(2.4rem, 6vw, 4rem);   line-height: 1.1; font-weight: 600; text-transform: uppercase; }
h2 { font-family: var(--font-display); font-size: clamp(1.8rem, 4vw, 2.8rem); line-height: 1.15; font-weight: 600; color: var(--plantation); text-transform: uppercase; }
h3 { font-family: var(--font-body);    font-size: clamp(1.05rem, 2vw, 1.3rem); font-weight: 600; line-height: 1.25; }
p  { color: var(--text-mid); }

.eyebrow {
  display: block;
  font-weight: 600;
  font-size: .71rem;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--serria);
  margin-bottom: .55rem;
}

/* ---- Layout ---- */
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 clamp(1.1rem, 5vw, 2.5rem); }
.section    { padding: var(--section-y) 0; }
.section--cream { background: var(--whiterock); }
.section--green { background: var(--plantation); }

.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: var(--gap); align-items: start; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap); }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: var(--gap); }
.grid-team { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: var(--gap); justify-content: center; }

.text-center { text-align: center; }
.section-header { max-width: 620px; margin: 0 auto 3rem; text-align: center; }
.section-header p { font-size: 1.05rem; margin-top: .6rem; }

/* ---- Buttons ---- */
.btn {
  display: inline-flex; align-items: center; gap: .5rem;
  font-weight: 600; font-size: .95rem;
  padding: .88rem 1.85rem;
  border-radius: var(--radius-pill);
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform var(--t), box-shadow var(--t), background var(--t), color var(--t), border-color var(--t);
  line-height: 1;
}
.btn:hover        { transform: translateY(-2px); }
.btn:focus-visible{ outline: 3px solid var(--serria); outline-offset: 3px; }
.btn svg          { flex: none; width: 18px; height: 18px; }

.btn--primary { background: var(--plantation); color: var(--white); box-shadow: var(--shadow-md); }
.btn--primary:hover { background: #1f3e38; box-shadow: var(--shadow-lg); }

.btn--outline { background: transparent; color: var(--plantation); border-color: var(--plantation); }
.btn--outline:hover { background: var(--plantation); color: var(--white); }

.btn--accent  { background: var(--serria); color: var(--white); box-shadow: 0 6px 18px rgba(219,144,77,.28); }
.btn--accent:hover { background: #c47d3b; }

.btn--white   { background: var(--white); color: var(--plantation); box-shadow: var(--shadow-md); }
.btn--white:hover { background: var(--whiterock); }

.btn--outline-white { background: transparent; color: var(--white); border-color: rgba(255,255,255,.55); }
.btn--outline-white:hover { background: rgba(255,255,255,.12); border-color: var(--white); }

/* ---- Navigation ---- */
.nav {
  position: sticky; top: 0; z-index: 200;
  background: var(--white);
  border-bottom: 1px solid rgba(44,85,77,.09);
  box-shadow: 0 1px 14px rgba(0,0,0,.06);
}
.nav__inner {
  max-width: var(--max-w); margin: 0 auto;
  padding: 0 clamp(1.1rem, 5vw, 2.5rem);
  display: flex; align-items: center; justify-content: space-between;
  height: 72px;
}
.nav__logo img { height: 46px; width: auto; }

.nav__links {
  display: flex; align-items: center; gap: 2rem;
}
.nav__links a {
  font-weight: 500; font-size: .95rem; color: var(--plantation);
  position: relative; transition: color var(--t);
}
.nav__links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0;
  width: 0; height: 2px; background: var(--serria);
  border-radius: 2px; transition: width var(--t);
}
.nav__links a:hover        { color: var(--serria); }
.nav__links a.active       { color: var(--serria); }
.nav__links a:hover::after,
.nav__links a.active::after { width: 100%; }

.nav__toggle {
  display: none; flex-direction: column; gap: 5px;
  background: none; border: none; cursor: pointer; padding: 4px;
}
.nav__toggle span {
  display: block; width: 24px; height: 2px;
  background: var(--plantation); border-radius: 2px;
  transition: transform .28s, opacity .28s;
}
.nav__toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__toggle.open span:nth-child(2) { opacity: 0; }
.nav__toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---- Page Hero (inner pages) ---- */
.page-hero {
  background: var(--plantation);
  padding: clamp(3.5rem, 8vw, 5.5rem) 0;
  text-align: center; position: relative; overflow: hidden;
}
.page-hero::before {
  content: ''; position: absolute; inset: 0;
  background-image: radial-gradient(circle at 20% 50%, rgba(240,234,222,.06) 0%, transparent 60%),
                    radial-gradient(circle at 80% 20%, rgba(219,144,77,.08) 0%, transparent 50%);
}
.page-hero .container { position: relative; z-index: 1; }
.page-hero h1    { color: var(--white); margin-bottom: .6rem; }
.page-hero .lead { color: rgba(255,255,255,.68); font-size: 1.08rem; max-width: 480px; margin: 0 auto; }

/* ---- Hero (homepage) ---- */
.hero {
  background-color: var(--whiterock);
  background-image: linear-gradient(rgba(255,255,255,.2), rgba(255,255,255,.2)), url("../assets/shapes1.png");
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
  position: relative; overflow: hidden;
  min-height: min(88vh, 820px);
  display: flex; align-items: center;
}
.hero__inner {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: clamp(2rem, 5vw, 5rem); align-items: center;
  padding: clamp(3rem, 7vw, 5rem) 0;
}
.hero__content { z-index: 1; }
.hero__content h1 { color: var(--plantation); margin-bottom: 1.1rem; }
.hero__content p  { font-size: 1.1rem; max-width: 460px; margin-bottom: 2rem; }
.hero__actions    { display: flex; gap: 1rem; flex-wrap: wrap; }
.hero__image      { display: flex; align-items: center; justify-content: center; }
.hero__image img  {
  max-width: 480px; width: 100%;
  animation: heroFloat 7s ease-in-out infinite;
  filter: drop-shadow(0 12px 32px rgba(44,85,77,.22));
}
.hero__deco {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 50%; pointer-events: none; opacity: .08;
}
.hero__deco svg { width: 100%; height: 100%; }

@keyframes heroFloat {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(-12px); }
}

/* ---- Feature Cards ---- */
.feature-card {
  background: var(--white); border-radius: var(--radius-lg);
  padding: 2rem; box-shadow: var(--shadow-sm);
  transition: transform var(--t), box-shadow var(--t);
}
.feature-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.feature-card__icon {
  width: 56px; height: 56px; border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.1rem;
}
.feature-card h3 { color: var(--plantation); margin-bottom: .5rem; }

.icon--green  { background: rgba(44,85,77,.1);    color: var(--plantation); }
.icon--orange { background: rgba(219,144,77,.13);  color: var(--serria); }
.icon--pink   { background: rgba(223,137,146,.13); color: var(--orchid); }
.icon--sage   { background: rgba(141,149,126,.15); color: var(--battleship); }
.icon--slate  { background: rgba(119,136,143,.13); color: var(--slate); }

.document-links { margin-top: 1rem; }
.document-avatar {
  display: flex; flex-direction: column; align-items: center; text-align: center;
  gap: .45rem; padding: 1.5rem 1rem; border-radius: var(--radius-lg);
  background: var(--white); box-shadow: var(--shadow-sm);
  transition: transform var(--t), box-shadow var(--t);
}
.document-avatar:hover { transform: translateY(-5px); box-shadow: var(--shadow-md); }
.document-avatar:focus-visible { outline: 3px solid var(--serria); outline-offset: 3px; }
.document-avatar__icon {
  width: 76px; height: 76px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; margin-bottom: .35rem;
}
.document-avatar--orange .document-avatar__icon { background: rgba(219,144,77,.15); color: var(--serria); }
.document-avatar--green .document-avatar__icon { background: rgba(44,85,77,.12); color: var(--plantation); }
.document-avatar--pink .document-avatar__icon { background: rgba(223,137,146,.15); color: var(--orchid); }
.document-avatar__title { color: var(--plantation); font-weight: 600; line-height: 1.25; }
.document-avatar__type { color: var(--text-light); font-size: .78rem; }

/* ---- About Snippet ---- */
.about-split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2.5rem, 6vw, 5rem); align-items: center; }
.about-split__visual {
  background: var(--plantation);
  border-radius: var(--radius-lg);
  min-height: 380px;
  display: flex; align-items: center; justify-content: center;
  position: relative; overflow: hidden;
}
.about-split__visual img {
  width: 75%; opacity: .92;
  animation: heroFloat 8s ease-in-out infinite 1s;
  filter: drop-shadow(0 8px 24px rgba(0,0,0,.3));
}
.about-split__visual .leaf {
  position: absolute;
  border-radius: 50% 0;
  opacity: .12; background: var(--battleship);
}

/* Full-bleed photo variant — for real photography rather than the small
   centred logo/illustration graphic above. */
.about-split__visual--photo img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center;
  opacity: 1; animation: none; filter: none;
}
.about-split__text .lead { font-size: 1.05rem; margin: 1rem 0 1.75rem; max-width: 460px; }
.stat-row { display: flex; gap: 2.5rem; margin-top: 2rem; flex-wrap: wrap; }
.stat      { border-left: 3px solid var(--serria); padding-left: 1rem; }
.stat strong { font-family: var(--font-display); font-size: 2rem; color: var(--plantation); display: block; text-transform: uppercase; }
.stat span   { font-size: .85rem; color: var(--text-light); text-transform: uppercase; letter-spacing: .06em; }

/* ---- Program Cards ---- */
.program-card {
  background: var(--white); border-radius: var(--radius-lg); overflow: hidden;
  box-shadow: var(--shadow-sm); transition: transform var(--t), box-shadow var(--t);
  display: flex; flex-direction: column;
}
.program-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.program-card__header {
  background: var(--plantation); padding: 2.5rem 2rem 2rem;
  position: relative; overflow: hidden;
}
.program-card__header--alt { background: #3d6e64; }
.program-card__header h3 { color: var(--white); font-family: var(--font-display); font-size: 1.5rem; margin-bottom: .3rem; text-transform: uppercase; }
.program-card__age  { color: var(--serria); font-size: .8rem; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; }
.program-card__body { padding: 2rem; flex: 1; }
.program-card__body p { margin-bottom: 1.2rem; }
.program-card__list  { display: flex; flex-direction: column; gap: .5rem; margin-bottom: 1.75rem; }
.program-card__list li {
  display: flex; align-items: flex-start; gap: .65rem;
  font-size: .9rem; color: var(--text-mid);
}
.program-card__list li::before {
  content: ''; flex: none; width: 7px; height: 7px;
  border-radius: 50%; background: var(--serria); margin-top: .55rem;
}

/* ---- Pull Quote ---- */
.quote-section {
  background: var(--plantation);
  padding: clamp(3.5rem, 7vw, 5rem) 0;
  text-align: center; position: relative; overflow: hidden;
}
.quote-section::before {
  content: '\201C';
  position: absolute; top: -2rem; left: 50%; transform: translateX(-50%);
  font-family: Georgia, serif; font-size: 18rem; line-height: 1;
  color: rgba(255,255,255,.05); pointer-events: none;
}
.quote-section blockquote {
  max-width: 680px; margin: 0 auto;
  font-family: var(--font-display); font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--white); line-height: 1.45; font-weight: 500; text-transform: uppercase;
}
.quote-section cite {
  display: block; margin-top: 1.5rem;
  font-style: normal; font-size: .9rem;
  color: var(--serria); font-weight: 600; letter-spacing: .05em;
}

/* ---- CTA Banner ---- */
.cta-banner {
  background: var(--serria); padding: clamp(3rem, 6vw, 4.5rem) 0;
  text-align: center;
}
.cta-banner h2 { color: var(--white); margin-bottom: .6rem; }
.cta-banner p  { color: rgba(255,255,255,.82); font-size: 1.05rem; max-width: 500px; margin: 0 auto 2rem; }
.cta-banner__actions { display: flex; gap: 1rem; flex-wrap: wrap; justify-content: center; }

/* ---- About Page: Values ---- */
.value-card {
  border-radius: var(--radius-lg); padding: 1.75rem;
  background: var(--white); box-shadow: var(--shadow-sm);
  border-top: 4px solid var(--plantation);
  transition: transform var(--t), box-shadow var(--t);
}
.value-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.value-card h3 { color: var(--plantation); margin-bottom: .5rem; }

.value-card--orange { border-color: var(--serria); }
.value-card--pink   { border-color: var(--orchid); }
.value-card--sage   { border-color: var(--battleship); }
.value-card--slate  { border-color: var(--slate); }

/* ---- About Page: Team ---- */
.team-card {
  text-align: center; border-radius: var(--radius-lg);
  background: var(--white); box-shadow: var(--shadow-sm);
  padding: 2rem 1.5rem;
  transition: transform var(--t), box-shadow var(--t);
}
.team-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.team-card__avatar {
  width: 128px; height: 128px; border-radius: 50%;
  margin: 0 auto 1.1rem;
  background: var(--whiterock);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
  box-shadow: 0 0 0 4px var(--whiterock), 0 0 0 5px rgba(44,85,77,.12);
}
.team-card__avatar svg { width: 60px; height: 60px; color: var(--battleship); }
.team-card__avatar img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: 50% 22%;
}
.team-card h3 { color: var(--plantation); font-size: 1.05rem; margin-bottom: .2rem; }
.team-card__role { color: var(--serria); font-size: .8rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; }
.team-card p { font-size: .88rem; margin-top: .6rem; }

/* ---- Montessori Philosophy ---- */
.philosophy-grid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: var(--gap);
  margin-top: 3rem;
}
.philosophy-item { text-align: center; }
.philosophy-item__num {
  font-family: var(--font-display); font-size: 3.5rem; font-weight: 700;
  color: var(--whiterock); line-height: 1;
  display: block; margin-bottom: .25rem; text-transform: uppercase;
}
.section--green .philosophy-item__num { color: rgba(240,234,222,.2); }
.philosophy-item h3 { color: var(--white); margin-bottom: .4rem; }
.philosophy-item p  { color: rgba(255,255,255,.65); font-size: .92rem; }

/* ---- Gallery ---- */
.filter-bar { display: flex; gap: .6rem; flex-wrap: wrap; justify-content: center; margin-bottom: 2.5rem; }
.filter-btn {
  background: var(--white); border: 2px solid rgba(44,85,77,.2);
  color: var(--plantation); border-radius: var(--radius-pill);
  padding: .5rem 1.25rem; font-size: .88rem; font-weight: 600;
  cursor: pointer; transition: background var(--t), border-color var(--t), color var(--t);
}
.filter-btn:hover  { border-color: var(--plantation); }
.filter-btn.active { background: var(--plantation); color: var(--white); border-color: var(--plantation); }

.gallery-grid {
  columns: 4;
  column-gap: 1.1rem;
}

.gallery-item { break-inside: avoid; margin-bottom: 1.1rem; }

.gallery-cell {
  border-radius: var(--radius-md); overflow: hidden;
  position: relative; display: block;
  box-shadow: var(--shadow-sm);
  transition: transform var(--t), box-shadow var(--t); cursor: pointer;
}
.gallery-cell img { width: 100%; height: auto; display: block; }
.gallery-cell:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); z-index: 1; }
.gallery-cell::after {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(44,85,77,.28), transparent 45%);
  opacity: 0; transition: opacity var(--t);
}
.gallery-cell:hover::after { opacity: 1; }
.gallery-cell__zoom {
  position: absolute; right: .6rem; bottom: .6rem;
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(255,255,255,.92); color: var(--plantation);
  display: flex; align-items: center; justify-content: center;
  opacity: 0; transform: scale(.8); transition: opacity var(--t), transform var(--t);
  pointer-events: none;
}
.gallery-cell:hover .gallery-cell__zoom { opacity: 1; transform: scale(1); }
.gallery-cell__zoom svg { width: 16px; height: 16px; }

@media (min-width: 1025px) and (max-width: 1240px) {
  .gallery-grid { columns: 3; }
}

/* ---- Contact ---- */
.contact-grid { display: grid; grid-template-columns: 1.15fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }

.form-group { display: flex; flex-direction: column; gap: .35rem; margin-bottom: 1.25rem; }
.form-group label { font-size: .85rem; font-weight: 600; color: var(--plantation); }
.form-control {
  width: 100%;
  background: var(--white); border: 2px solid rgba(44,85,77,.18);
  border-radius: var(--radius-md); padding: .8rem 1rem;
  font-size: .95rem; color: var(--text);
  transition: border-color var(--t), box-shadow var(--t);
}
.form-control:focus { outline: none; border-color: var(--plantation); box-shadow: 0 0 0 3px rgba(44,85,77,.1); }
.form-control::placeholder { color: #bbb; }
textarea.form-control { resize: vertical; min-height: 130px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

.form-card {
  background: var(--white); border-radius: var(--radius-lg);
  padding: 2.25rem; box-shadow: var(--shadow-md);
}
.form-card h2 { color: var(--plantation); margin-bottom: 1.75rem; }

.info-panel { display: flex; flex-direction: column; gap: 1.25rem; }
.info-block {
  background: var(--white); border-radius: var(--radius-lg);
  padding: 1.6rem; box-shadow: var(--shadow-sm);
  display: flex; gap: 1rem; align-items: flex-start;
}
.info-block__icon {
  width: 44px; height: 44px; border-radius: var(--radius-sm); flex: none;
  display: flex; align-items: center; justify-content: center;
}
.info-block h4 { color: var(--plantation); font-size: .95rem; margin-bottom: .2rem; }
.info-block p, .info-block a { font-size: .9rem; color: var(--text-mid); }
.info-block a:hover { color: var(--serria); }

.hours-table { width: 100%; border-collapse: collapse; margin-top: .25rem; }
.hours-table td { font-size: .87rem; color: var(--text-mid); padding: .35rem 0; vertical-align: top; }
.hours-table td:last-child { width: 1%; text-align: right; color: var(--plantation); font-weight: 500; white-space: nowrap; padding-left: 1rem; }

/* ---- Footer ---- */
.footer {
  background: var(--plantation);
  padding: clamp(2.5rem, 5vw, 4rem) 0 1.5rem;
}
.footer__grid {
  display: grid; grid-template-columns: 1.6fr 1fr 1fr;
  gap: clamp(1.5rem, 4vw, 3rem); margin-bottom: 2.5rem;
}
.footer__brand-name {
  font-family: var(--font-display); font-size: 1.35rem;
  font-weight: 600; color: var(--white); display: block; text-transform: uppercase;
}
.footer__brand-sub {
  display: block; color: var(--serria);
  font-size: .72rem; letter-spacing: .12em;
  text-transform: uppercase; font-weight: 600; margin-bottom: 1rem;
}
.footer p  { font-size: .88rem; color: rgba(255,255,255,.55); }
.footer h4 {
  font-size: .8rem; font-weight: 700; letter-spacing: .1em;
  text-transform: uppercase; color: rgba(255,255,255,.4);
  margin-bottom: 1rem;
}
.footer__links { display: flex; flex-direction: column; gap: .55rem; }
.footer__links a { font-size: .9rem; color: rgba(255,255,255,.65); transition: color var(--t); }
.footer__links a:hover { color: var(--serria); }
.footer__contact-item {
  display: flex; gap: .65rem; align-items: flex-start;
  font-size: .88rem; color: rgba(255,255,255,.65); margin-bottom: .6rem;
}
.footer__contact-item svg { flex: none; width: 16px; height: 16px; margin-top: .25rem; opacity: .6; color: var(--serria); }
.footer__contact-item a:hover { color: var(--serria); }
.footer__bottom {
  border-top: 1px solid rgba(255,255,255,.1);
  padding-top: 1.5rem;
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: .75rem;
  font-size: .78rem; color: rgba(255,255,255,.3);
}

/* ---- Decorative roots SVG ---- */
.roots-bg {
  position: absolute; bottom: 0; left: 0; width: 100%;
  pointer-events: none; opacity: .08; z-index: 0;
}
.roots-bg path { fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }

/* ---- Animations ---- */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity .65s ease, transform .65s ease; }
.reveal.visible { opacity: 1; transform: none; }
.reveal-2 { transition-delay: .12s; }
.reveal-3 { transition-delay: .24s; }
.reveal-4 { transition-delay: .36s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero__image img { animation: none; }
  .about-split__visual img { animation: none; }
}

/* ---- Responsive ---- */
@media (max-width: 768px) {
  .nav__toggle  { display: flex; }
  .nav__links {
    display: none; position: absolute; top: 72px; left: 0; right: 0;
    background: var(--white); flex-direction: column; gap: 0; padding: 1rem 0 1.5rem;
    border-bottom: 1px solid rgba(44,85,77,.1);
    box-shadow: 0 10px 24px rgba(0,0,0,.09); z-index: 199;
  }
  .nav__links.open  { display: flex; }
  .nav__links a     { padding: .78rem 2rem; font-size: 1rem; }
  .nav__links a::after { display: none; }

  .hero__inner      { grid-template-columns: 1fr; text-align: center; }
  .hero__image      { order: -1; }
  .hero__image img  { max-width: 280px; margin: 0 auto; }
  .hero__content p  { margin-left: auto; margin-right: auto; }
  .hero__actions    { justify-content: center; }

  /* Lighter tile grids stay 2-up on phones so users aren't scrolling
     through a long single-file list; only content-heavy cards go 1-up. */
  .grid-2           { grid-template-columns: 1fr; }
  .grid-3, .grid-4  { grid-template-columns: repeat(2, 1fr); gap: clamp(.75rem, 3vw, 1.25rem); }
  .grid-3--steps    { grid-template-columns: 1fr; }
  .grid-team        { grid-template-columns: repeat(2, 1fr); gap: clamp(.75rem, 3vw, 1.25rem); }
  .philosophy-grid  { grid-template-columns: repeat(2, 1fr); }
  .about-split, .contact-grid { grid-template-columns: 1fr; }
  .form-row         { grid-template-columns: 1fr; }
  .gallery-grid     { columns: 2; column-gap: .75rem; }
  .gallery-item     { margin-bottom: .75rem; }
  .stat-row         { gap: 1.5rem; }
  .footer__grid     { grid-template-columns: 1fr; gap: 2rem; }
  .footer__bottom   { flex-direction: column; text-align: center; }
  .about-split__visual { min-height: 260px; }

  /* Smaller tiles need less internal padding at 2-up to avoid feeling cramped */
  .feature-card     { padding: 1.5rem 1.25rem; }
  .value-card       { padding: 1.35rem; }
  .document-avatar  { padding: 1.25rem .75rem; }
  .team-card        { padding: 1.5rem 1rem; }
  .team-card__avatar { width: 96px; height: 96px; }
  .document-avatar__icon { width: 60px; height: 60px; }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .grid-4           { grid-template-columns: repeat(2, 1fr); }
  .philosophy-grid  { grid-template-columns: repeat(2, 1fr); }
}

/* Very small/old phones (iPhone SE 1st-gen and similar, ~320px): even
   light 2-up tiles get tight, so drop to 1-up only at this width. */
@media (max-width: 340px) {
  .grid-3, .grid-4, .grid-team, .philosophy-grid { grid-template-columns: 1fr; }
  .team-card__avatar { width: 128px; height: 128px; }
  .document-avatar__icon { width: 76px; height: 76px; }
  .gallery-grid { columns: 1; }
}
