/* ==========================================================================
   IAPSIT — International Association of Professionals in Sugar
   and Integrated Technologies
   Design system: cane-field green + molasses gold, hexagon signature motif
   ========================================================================== */

:root {
  /* Colour tokens */
  --cane-deep:      #163d24;   /* deep cane-leaf green, near-black */
  --cane-forest:    #1f5c37;   /* primary green */
  --cane-fresh:     #3f8f4f;   /* growth green, links/accents */
  --cane-mist:      #eef4e6;   /* pale field-mist green, section bg */
  --cream:          #faf8f1;   /* page background */
  --molasses:       #c98a2e;   /* gold accent (raw sugar / molasses) */
  --molasses-deep:  #9c6a1f;
  --ink:            #1c2418;   /* body text */
  --ink-soft:       #4b5a45;   /* secondary text */
  --line:           #dbe3d2;   /* hairline borders */
  --white:          #ffffff;

  /* Type */
  --font-display: "Fraunces", "Georgia", serif;
  --font-body: "Source Sans 3", "Segoe UI", Arial, sans-serif;

  --radius: 10px;
  --shadow-soft: 0 10px 30px -12px rgba(22, 61, 36, 0.25);
  --shadow-card: 0 6px 18px -8px rgba(22, 61, 36, 0.22);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background: var(--cream);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

a { color: inherit; text-decoration: none; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--cane-deep);
  line-height: 1.15;
  margin: 0 0 0.5em;
  font-weight: 600;
}

h1 { font-size: clamp(2.1rem, 4vw, 3.4rem); font-weight: 700; }
h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); }
h3 { font-size: 1.3rem; }

p { margin: 0 0 1em; color: var(--ink); }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-body);
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.75rem;
  color: var(--molasses-deep);
  margin-bottom: 0.9em;
}
.eyebrow::before {
  content: "";
  width: 22px;
  height: 2px;
  background: var(--molasses);
  display: inline-block;
}

.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 24px;
}

.btn {
  display: inline-block;
  padding: 13px 28px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color .18s ease;
}
.btn-primary {
  background: var(--molasses);
  color: var(--white);
  box-shadow: var(--shadow-card);
}
.btn-primary:hover { background: var(--molasses-deep); transform: translateY(-2px); }
.btn-outline {
  background: transparent;
  border-color: var(--white);
  color: var(--white);
}
.btn-outline:hover { background: var(--white); color: var(--cane-deep); transform: translateY(-2px); }
.btn-ghost {
  background: transparent;
  border-color: var(--cane-forest);
  color: var(--cane-forest);
}
.btn-ghost:hover { background: var(--cane-forest); color: var(--white); }

/* ---------------------------------------------------------------- topbar */
.topbar {
  background: var(--cane-deep);
  color: #cfe3cf;
  font-size: 0.82rem;
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 7px;
  padding-bottom: 7px;
  flex-wrap: wrap;
  gap: 6px;
}
.topbar a { color: #e9f2df; }
.topbar a:hover { color: var(--molasses); }
.topbar-links { display: flex; gap: 18px; }
.topbar-links span { opacity: .55; margin: 0 4px; }

/* ------------------------------------------------------------- site head */
.site-header {
  background: var(--cream);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 50;
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  padding-bottom: 14px;
  gap: 20px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}
.brand img { width: 62px; height: 62px; border-radius: 50%; flex-shrink: 0; }
.brand-text .name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.28rem;
  color: var(--cane-deep);
  display: block;
}
.brand-text .tag {
  font-size: 0.78rem;
  color: var(--ink-soft);
  display: block;
  max-width: 420px;
}

.main-nav ul {
  list-style: none;
  display: flex;
  gap: 4px;
  margin: 0;
  padding: 0;
}
.main-nav a {
  display: block;
  padding: 11px 18px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--cane-deep);
  transition: background .18s ease, color .18s ease;
}
.main-nav a:hover { background: var(--cane-mist); }
.main-nav a.active { background: var(--cane-forest); color: var(--white); }

.nav-toggle {
  display: none;
  background: var(--cane-forest);
  border: none;
  border-radius: 8px;
  width: 44px;
  height: 40px;
  cursor: pointer;
  position: relative;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  height: 2px;
  background: var(--white);
}
.nav-toggle span { top: 19px; }
.nav-toggle span::before { top: -7px; }
.nav-toggle span::after { top: 7px; }

/* ------------------------------------------------------------------ hero */
.hero {
  position: relative;
  color: var(--white);
  background: linear-gradient(120deg, rgba(15,40,24,.93), rgba(31,92,55,.86)), url('../images/cane-field-row.jpg');
  background-size: cover;
  background-position: center 65%;
  overflow: hidden;
}
.hero .container {
  padding-top: 84px;
  padding-bottom: 92px;
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 40px;
  align-items: center;
  position: relative;
  z-index: 2;
}
.hero-eyebrow {
  color: #cfe6b9;
}
.hero h1 { color: var(--white); }
.hero h1 em { color: #f0c069; font-style: normal; }
.hero-lede {
  font-size: 1.12rem;
  color: #e4efdd;
  max-width: 46ch;
}
.hero-cta { display: flex; gap: 14px; margin-top: 26px; flex-wrap: wrap; }
.hero-stats {
  display: flex;
  gap: 26px;
  margin-top: 44px;
  flex-wrap: wrap;
}
.hero-stats div strong {
  display: block;
  font-family: var(--font-display);
  font-size: 1.6rem;
  color: var(--molasses);
}
.hero-stats div span { font-size: 0.8rem; color: #d5e6cb; }

/* Hero reference visual — single framed image */
.hero-media {
  position: relative;
  max-width: 480px;
  margin: 0 auto;
  border-radius: 14px;
  overflow: hidden;
  border: 6px solid rgba(255,255,255,0.92);
  box-shadow: 0 20px 45px -14px rgba(0,0,0,0.5);
  background: var(--white);
}
.hero-media img { width: 100%; height: auto; display: block; }

/* Hero hexagon collage — transparent PNG, no card frame */
.hero-hex {
  max-width: 460px;
  margin: 0 auto;
  filter: drop-shadow(0 22px 34px rgba(0,0,0,0.45));
}
.hero-hex img { width: 100%; height: auto; display: block; }

/* Hexagon photo cluster — the site's signature visual device (retained for other sections) */
.hex-cluster {
  --s: 108px;
  position: relative;
  width: 100%;
  max-width: 380px;
  margin: 0 auto;
  aspect-ratio: 1 / 1.05;
}
.hex {
  position: absolute;
  width: var(--s);
  aspect-ratio: 0.87;
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 25%, 0% 75%);
  overflow: hidden;
  border: 3px solid rgba(255,255,255,0.85);
  box-shadow: 0 8px 18px rgba(0,0,0,.28);
}
.hex img { width: 100%; height: 100%; object-fit: cover; }
.hex1 { top: 0;    left: 25%; }
.hex2 { top: 16%;  left: 0%; }
.hex3 { top: 16%;  left: 50%; }
.hex4 { top: 47%;  left: 25%; background: var(--molasses); display:flex; align-items:center; justify-content:center; }
.hex5 { top: 63%;  left: 0%; }
.hex6 { top: 63%;  left: 50%; }
.hex4 .hex-label {
  color: var(--white);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.95rem;
  text-align: center;
  padding: 0 10px;
}

/* -------------------------------------------------------------- section */
section { padding: 76px 0; }
.section-mist { background: var(--cane-mist); }
.section-head {
  max-width: 680px;
  margin: 0 auto 44px;
  text-align: center;
}
.section-head.left { margin: 0 0 40px; text-align: left; }

.about-block {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.about-copy .lede {
  font-size: 1.18rem;
  color: var(--cane-deep);
  font-family: var(--font-display);
  font-weight: 500;
  line-height: 1.5;
}
.stalk-divider {
  height: 34px;
  margin: 8px 0 28px;
  background-repeat: repeat-x;
  background-size: 34px 34px;
  opacity: .55;
}
.about-media {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}
.about-media img { width: 100%; height: 420px; object-fit: cover; }

/* --------------------------------------------------------- crop mosaic */
.crop-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.crop-card {
  background: var(--white);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform .22s ease, box-shadow .22s ease;
}
.crop-card:hover { transform: translateY(-6px); box-shadow: 0 18px 30px -12px rgba(22,61,36,.32); }
.crop-card .thumb { height: 190px; overflow: hidden; }
.crop-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.crop-card:hover .thumb img { transform: scale(1.08); }
.crop-card .body { padding: 20px 22px 24px; }
.crop-card h3 { margin-bottom: 6px; font-size: 1.15rem; }
.crop-card p { font-size: 0.93rem; color: var(--ink-soft); margin: 0; }
.crop-tag {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--cane-forest);
  background: var(--cane-mist);
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
}

/* --------------------------------------------------------- value chain */
.chain {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  counter-reset: chain;
}
.chain-step {
  background: var(--white);
  padding: 26px 20px;
  position: relative;
  border-top: 4px solid var(--molasses);
}
.chain-step .thumb { height: 130px; border-radius: 8px; overflow: hidden; margin-bottom: 16px; }
.chain-step .thumb img { width: 100%; height: 100%; object-fit: cover; }
.chain-step h4 { font-size: 1.02rem; margin-bottom: 6px; }
.chain-step p { font-size: 0.87rem; color: var(--ink-soft); margin: 0; }

/* ------------------------------------------------------------ event card */
.event-card {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 0;
  background: var(--white);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  border: 1px solid var(--line);
}
.event-media { position: relative; overflow: hidden; }
.event-media img { width: 100%; height: 100%; object-fit: cover; min-height: 320px; transition: transform .5s ease; }
.event-card:hover .event-media img { transform: scale(1.04); }
.event-media .ribbon {
  position: absolute;
  top: 18px;
  left: -46px;
  background: var(--molasses);
  color: var(--white);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: .05em;
  padding: 7px 50px;
  transform: rotate(-40deg);
  box-shadow: 0 4px 10px rgba(0,0,0,.25);
}
.event-body { padding: 40px 42px; display: flex; flex-direction: column; justify-content: center; }
.event-body .eyebrow { color: var(--molasses-deep); }
.event-body h3 { font-size: 1.7rem; margin-bottom: 10px; }
.event-body .theme { font-style: italic; color: var(--cane-forest); font-weight: 600; margin-bottom: 18px; }
.event-meta { list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 10px; }
.event-meta li { display: flex; gap: 10px; font-size: 0.95rem; color: var(--ink); }
.event-meta li b { color: var(--cane-deep); min-width: 88px; display: inline-block; }
.event-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* -------------------------------------------------------------- isc full */
.isc-banner {
  background: var(--cane-deep);
  color: var(--white);
}
.isc-flex {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 50px;
  align-items: center;
}
.isc-flex img { border-radius: 14px; box-shadow: var(--shadow-soft); }
.isc-flex h2 { color: var(--white); }
.isc-flex p { color: #dcead0; }
.isc-flex .theme { color: var(--molasses); font-style: italic; font-weight: 600; font-size: 1.05rem; }

/* --------------------------------------------------------------- stats */
.stat-strip {
  background: var(--cane-forest);
  color: var(--white);
}
.stat-strip .container {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  text-align: center;
}
.stat-strip strong { display: block; font-family: var(--font-display); font-size: 2.1rem; color: var(--white); }
.stat-strip span { font-size: 0.85rem; color: #cfe6c2; letter-spacing: .03em; }

/* ----------------------------------------------------------- newsletter */
.cta-band {
  background: linear-gradient(120deg, var(--molasses), var(--molasses-deep));
  color: var(--white);
}
.cta-band .container { display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.cta-band h2 { color: var(--white); margin-bottom: 6px; }
.cta-band p { color: #fff2dc; margin: 0; }

/* -------------------------------------------------------------- footer */
.site-footer {
  background: var(--cane-deep);
  color: #cfe0c4;
  padding-top: 60px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 0.8fr 0.8fr 1fr;
  gap: 40px;
  padding-bottom: 44px;
  border-bottom: 1px solid rgba(255,255,255,.12);
}
.footer-grid h4 {
  color: var(--white);
  font-size: 0.95rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  margin-bottom: 16px;
}
.footer-brand { display: flex; gap: 12px; align-items: center; margin-bottom: 14px; }
.footer-brand img { width: 48px; height: 48px; border-radius: 50%; }
.footer-brand strong { color: var(--white); font-family: var(--font-display); font-size: 1.1rem; }
.footer-grid p, .footer-grid a { font-size: 0.9rem; color: #b9cfae; }
.footer-grid ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.footer-grid a:hover { color: var(--molasses); }
.social-row { display: flex; gap: 10px; margin-top: 16px; }
.social-row a {
  width: 36px; height: 36px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.25);
  display: flex; align-items: center; justify-content: center;
  font-size: .85rem;
}
.social-row a:hover { background: var(--molasses); border-color: var(--molasses); }
.footer-bottom {
  padding: 20px 0 26px;
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  font-size: 0.82rem;
  color: #93a988;
}

/* ------------------------------------------------------------- sub page */
.page-hero {
  background: linear-gradient(120deg, rgba(15,40,24,.92), rgba(31,92,55,.85)), url('../images/sugarcane-closeup.jpg');
  background-size: cover;
  background-position: center;
  color: var(--white);
  padding: 66px 0;
  text-align: center;
}
.page-hero h1 { color: var(--white); margin-bottom: 8px; }
.breadcrumb { font-size: .85rem; color: #cfe6c2; }
.breadcrumb a { color: #f0c069; }

.placeholder-card {
  background: var(--white);
  border: 1.5px dashed var(--cane-forest);
  border-radius: var(--radius);
  padding: 46px;
  text-align: center;
  max-width: 720px;
  margin: 0 auto;
}
.placeholder-card .icon-ring {
  width: 66px; height: 66px; border-radius: 50%;
  background: var(--cane-mist);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 18px;
  font-size: 1.6rem;
}
.placeholder-card h3 { margin-bottom: 10px; }
.placeholder-card p { color: var(--ink-soft); }

.simple-form { display: grid; gap: 18px; max-width: 640px; margin: 0 auto; }
.simple-form label { font-weight: 700; font-size: 0.88rem; color: var(--cane-deep); display: block; margin-bottom: 6px; }
.simple-form input, .simple-form select, .simple-form textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--line);
  border-radius: 8px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  background: var(--white);
  color: var(--ink);
}
.simple-form input:focus, .simple-form select:focus, .simple-form textarea:focus {
  outline: none;
  border-color: var(--cane-forest);
  box-shadow: 0 0 0 3px rgba(63,143,79,.18);
}
.rating-row { display: flex; gap: 10px; }
.rating-row label {
  display: flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 50%;
  border: 1.5px solid var(--line);
  cursor: pointer;
  font-weight: 700;
  color: var(--cane-deep);
  margin: 0;
}
.rating-row input { display: none; }
.rating-row input:checked + span { display: none; }
.form-note { font-size: 0.82rem; color: var(--ink-soft); text-align: center; }

.contact-grid { display: grid; grid-template-columns: 0.9fr 1.1fr; gap: 50px; }
.contact-info-card {
  background: var(--cane-deep);
  color: var(--white);
  border-radius: var(--radius);
  padding: 40px;
}
.contact-info-card h3 { color: var(--white); }
.contact-info-card ul { list-style: none; padding: 0; margin: 24px 0 0; display: grid; gap: 20px; }
.contact-info-card li { display: flex; gap: 14px; font-size: 0.92rem; color: #dcead0; }
.contact-info-card .ic {
  width: 38px; height: 38px; border-radius: 50%;
  background: rgba(255,255,255,.12);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}

.team-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.team-card { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow-card); overflow: hidden; text-align: center; padding-bottom: 22px; }
.team-avatar { height: 260px; background: var(--cane-mist); display: flex; align-items: center; justify-content: center; font-size: 2.2rem; color: var(--cane-forest); margin-bottom: 16px; overflow: hidden; }
.team-avatar img { width: 100%; height: 100%; object-fit: contain; object-position: center top; }
.team-card h4 { margin-bottom: 4px; font-size: 1rem; }
.team-card span { font-size: 0.8rem; color: var(--ink-soft); }

/* ----------------------------------------------------------- utilities */
.mt-0 { margin-top: 0; }
.text-center { text-align: center; }
.tag-list { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.tag-list span {
  background: var(--cane-mist);
  color: var(--cane-forest);
  font-size: 0.8rem;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 999px;
}

/* -------------------------------------------------------------- footer credit */
.back-top {
  position: fixed;
  right: 22px;
  bottom: 22px;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: var(--molasses);
  color: var(--white);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-soft);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease, transform .25s ease;
  z-index: 60;
}
.back-top.show { opacity: 1; pointer-events: auto; }

/* ================================================================= responsive */
@media (max-width: 980px) {
  .hero .container { grid-template-columns: 1fr; }
  .hex-cluster { max-width: 300px; }
  .hero-hex { max-width: 340px; margin: 36px auto 0; }
  .about-block { grid-template-columns: 1fr; }
  .about-media img { height: 300px; }
  .isc-flex { grid-template-columns: 1fr; }
  .event-card { grid-template-columns: 1fr; }
  .event-media img { min-height: 240px; }
  .chain { grid-template-columns: repeat(2, 1fr); gap: 18px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .contact-grid { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: repeat(2, 1fr); }
  .event-body { padding: 32px 26px; }
}

@media (max-width: 760px) {
  .crop-grid { grid-template-columns: 1fr 1fr; }
  .stat-strip .container { grid-template-columns: 1fr 1fr; }
  .topbar .container { justify-content: center; text-align: center; }
}

/* Tablet / small-laptop: switch to the mobile nav pattern earlier so the
   five nav links + tagline never get cramped on iPad-width screens */
@media (max-width: 900px) {
  .brand-text .tag { display: none; }
  .main-nav { position: fixed; top: 0; right: -100%; height: 100vh; width: 78%; max-width: 320px;
    background: var(--cream); box-shadow: -8px 0 30px rgba(0,0,0,.2); transition: right .3s ease; padding: 90px 26px 26px;
    overflow-y: auto; }
  .main-nav.open { right: 0; }
  .main-nav ul { flex-direction: column; }
  .main-nav a { padding: 14px 12px; }
  .nav-toggle { display: block; }
}

@media (max-width: 560px) {
  .crop-grid { grid-template-columns: 1fr; }
  .chain { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .team-grid { grid-template-columns: 1fr; }
  .stat-strip .container { grid-template-columns: 1fr; }
  section { padding: 54px 0; }
  .hero-hex { max-width: 240px; }
  .hero-stats { gap: 18px 26px; }
  .event-media .ribbon { left: -52px; font-size: .7rem; padding: 6px 46px; }
  .contact-info-card, .placeholder-card { padding: 30px 22px; }
  .brand img { width: 50px; height: 50px; }
}
