/* ============================================
   Liddell Lodge No. 3616 — Design System
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,600;1,300;1,400;1,600&family=Jost:wght@300;400;500&display=swap');

:root {
  --gold: #C9A84C;
  --gold-light: #E8C97A;
  --navy: #0A0F1E;
  --navy-mid: #121929;
  --navy-light: #1C2840;
  --white: #F5F0E8;
  --grey: #9AA0B0;
  --font-serif: 'Cormorant Garamond', serif;
  --transition: 0.25s ease;
  --nav-height: 80px;
  --nav-height-shrink: 56px;
  --container-max: 1100px;
  --section-padding: 5rem 1.5rem;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Jost', sans-serif;
  font-weight: 400;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--white);
  background-color: var(--navy);
  min-height: 100vh;
  overflow-x: hidden;
  display: flex;
  flex-direction: column;
}

body > main {
  flex: 1;
}

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

a {
  color: var(--gold);
  text-decoration: none;
  transition: color var(--transition);
}

a:hover {
  color: var(--gold-light);
}

/* ============================================
   Typography
   ============================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  line-height: 1.2;
}

h1 { font-size: clamp(2.25rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.75rem, 3vw, 2.5rem); font-weight: 600; }
h3 { font-size: clamp(1.25rem, 2vw, 1.5rem); }

.eyebrow {
  font-family: 'Jost', sans-serif;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.5rem;
}

/* ============================================
   Layout
   ============================================ */

.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

.section {
  padding: var(--section-padding);
}

/* ============================================
   Navigation
   ============================================ */

.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  height: var(--nav-height);
  padding: 0 1.5rem;
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: height var(--transition), padding var(--transition);
}

.nav.is-shrunk {
  height: var(--nav-height-shrink);
  padding: 0 1.25rem;
}

.nav__logo {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.nav__logo-main {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--gold);
}

.nav__logo-no {
  font-family: 'Jost', sans-serif;
  font-size: 0.7rem;
  font-weight: 400;
  color: var(--grey);
  letter-spacing: 0.05em;
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 2rem;
  list-style: none;
}

.nav__links a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--white);
  position: relative;
}

.nav__links a:hover,
.nav__links a.nav__link--active {
  color: var(--gold);
}

.nav__links a.nav__link--active::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  right: 0;
  height: 1px;
  background: var(--gold);
}

/* Hamburger */
.nav__toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 28px;
  height: 28px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav__toggle span {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--white);
  transition: var(--transition);
}

.nav__toggle.is-open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav__toggle.is-open span:nth-child(2) {
  opacity: 0;
}

.nav__toggle.is-open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* ============================================
   Footer
   ============================================ */

.footer {
  background: var(--navy-mid);
  border-top: 3px solid var(--gold);
  padding: 2.5rem 1.5rem;
  margin-top: auto;
}

.footer .container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
}

.footer__name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.1rem;
  color: var(--gold);
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
  list-style: none;
}

.footer__nav a {
  font-size: 0.9rem;
  color: var(--grey);
}

.footer__nav a:hover {
  color: var(--gold-light);
}

.footer__copy {
  font-size: 0.8rem;
  color: var(--grey);
}

/* ============================================
   Buttons
   ============================================ */

.btn {
  display: inline-block;
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  font-weight: 500;
  padding: 0.85rem 1.75rem;
  border: 2px solid var(--gold);
  cursor: pointer;
  transition: background var(--transition), color var(--transition), transform var(--transition);
  text-align: center;
}

.btn--primary {
  background: var(--gold);
  color: var(--navy);
  border-color: var(--gold);
}

.btn--primary:hover {
  background: var(--gold-light);
  border-color: var(--gold-light);
  color: var(--navy);
}

.btn--outline {
  background: transparent;
  color: var(--gold);
}

.btn--outline:hover {
  background: rgba(201, 168, 76, 0.15);
  color: var(--gold-light);
}

.btn--full {
  width: 100%;
}

/* ============================================
   Hero (Homepage)
   ============================================ */

.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: calc(var(--nav-height) + 3rem) 1.5rem 4rem;
  overflow: hidden;
}

.hero__bg {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(90deg, rgba(201, 168, 76, 0.03) 1px, transparent 1px),
    linear-gradient(rgba(201, 168, 76, 0.03) 1px, transparent 1px);
  background-size: 40px 40px;
  background-color: var(--navy);
}

.hero__watermark {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(60vw, 500px);
  height: auto;
  opacity: 0.06;
  pointer-events: none;
}

.hero__content {
  position: relative;
  z-index: 1;
  text-align: center;
  max-width: 720px;
}

.hero__eyebrow {
  opacity: 0;
  animation: fadeUp 0.8s ease forwards;
  animation-delay: 0.2s;
  animation-fill-mode: both;
}

.hero__title {
  opacity: 0;
  animation: fadeUp 0.8s ease forwards;
  animation-delay: 0.4s;
  animation-fill-mode: both;
  margin-bottom: 0.75rem;
}

.hero__subtitle {
  font-size: clamp(1rem, 2vw, 1.2rem);
  font-weight: 300;
  color: var(--grey);
  opacity: 0;
  animation: fadeUp 0.8s ease forwards;
  animation-delay: 0.6s;
  animation-fill-mode: both;
  margin-bottom: 1.5rem;
  line-height: 1.6;
}

.hero__meta {
  font-size: 0.85rem;
  color: var(--grey);
  opacity: 0;
  animation: fadeUp 0.8s ease forwards;
  animation-delay: 0.8s;
  animation-fill-mode: both;
  margin-bottom: 2rem;
}

.hero__ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
  opacity: 0;
  animation: fadeUp 0.8s ease forwards;
  animation-delay: 1s;
  animation-fill-mode: both;
  margin-bottom: 3rem;
}

.hero__scroll {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  opacity: 0;
  animation: fadeUp 0.8s ease forwards 1.2s, bounce 2s ease infinite 2s;
  animation-fill-mode: both;
}

.hero__scroll svg {
  width: 28px;
  height: 28px;
  stroke: var(--gold);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ============================================
   Core Values Strip (Homepage)
   ============================================ */

.values {
  background: var(--navy-mid);
  padding: 3rem 1.5rem;
  border-top: 1px solid rgba(201, 168, 76, 0.15);
}

.values .container {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  text-align: center;
}

.values__item {
  padding: 1rem;
}

.values__icon {
  width: 48px;
  height: 48px;
  margin: 0 auto 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-size: 1.5rem;
}

.values__item h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  color: var(--white);
}

.values__item p {
  font-size: 0.9rem;
  color: var(--grey);
  font-weight: 300;
}

/* ============================================
   Stats Row
   ============================================ */

.stats {
  padding: 3rem 1.5rem;
  border-top: 1px solid rgba(201, 168, 76, 0.08);
}

.stats .container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem 3rem;
}

.stats__item {
  text-align: center;
}

.stats__value {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.75rem;
  font-weight: 600;
  color: var(--gold);
  display: block;
}

.stats__label {
  font-size: 0.8rem;
  color: var(--grey);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* ============================================
   Scroll-reveal (utility)
   ============================================ */

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================
   Cards (generic)
   ============================================ */

.card {
  background: var(--navy-mid);
  border: 1px solid rgba(201, 168, 76, 0.15);
  padding: 1.75rem;
  transition: transform var(--transition), border-color var(--transition);
}

.card:hover {
  transform: translateY(-4px);
  border-color: var(--gold);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}

.card--gold-border {
  border-left: 4px solid var(--gold);
}

.card__date {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.05em;
  margin-bottom: 0.5rem;
}

.card__title {
  margin-bottom: 0.5rem;
}

.card__title a {
  color: var(--white);
}

.card__title a:hover {
  color: var(--gold-light);
}

.card__desc {
  font-size: 0.95rem;
  color: var(--grey);
  margin-bottom: 1rem;
  font-weight: 300;
}

.card__link {
  font-size: 0.9rem;
  font-weight: 500;
}

/* ============================================
   Page Headers (inner pages)
   ============================================ */

.page-hero {
  padding: calc(var(--nav-height) + 4rem) 1.5rem 3rem;
  text-align: center;
  background: var(--navy-mid);
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
}

.page-hero h1 {
  margin-bottom: 0.5rem;
}

.page-hero p {
  color: var(--grey);
  max-width: 560px;
  margin: 0 auto;
}

/* ============================================
   Content Sections
   ============================================ */

.content-section h2 {
  margin-bottom: 1.5rem;
  color: var(--white);
}

.content-section p {
  margin-bottom: 1rem;
  color: var(--grey);
  font-weight: 300;
}

.content-section p:last-child {
  margin-bottom: 0;
}

/* ============================================
   Meeting Months Grid
   ============================================ */

.months-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 2rem;
}

.month-chip {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-size: 0.9rem;
  font-weight: 500;
}

/* ============================================
   Links Page Cards
   ============================================ */

.link-card {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  background: var(--navy-mid);
  border: 1px solid rgba(201, 168, 76, 0.15);
  transition: transform var(--transition), border-color var(--transition);
  margin-bottom: 1rem;
}

.link-card:hover {
  transform: translateY(-4px);
  border-color: var(--gold);
}

.link-card::before {
  content: '';
  flex-shrink: 0;
  width: 8px;
  height: 8px;
  background: var(--gold);
  margin-top: 0.5rem;
}

.link-card a {
  color: var(--white);
  font-weight: 500;
}

.link-card a:hover {
  color: var(--gold-light);
}

.link-card .link-card__url {
  font-size: 0.85rem;
  color: var(--grey);
  margin-top: 0.25rem;
}

.link-card .link-card__tbc {
  font-size: 0.85rem;
  color: var(--grey);
  font-style: italic;
}

/* ============================================
   Contact Page
   ============================================ */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.contact-form label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 0.35rem;
  color: var(--white);
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  margin-bottom: 1.25rem;
  font-family: 'Jost', sans-serif;
  font-size: 1rem;
  color: var(--white);
  background: var(--navy-mid);
  border: 1px solid rgba(201, 168, 76, 0.25);
  transition: border-color var(--transition);
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--gold);
}

.contact-form textarea {
  min-height: 140px;
  resize: vertical;
}

.contact-form input::placeholder,
.contact-form textarea::placeholder {
  color: var(--grey);
  opacity: 0.8;
}

.contact-form__checkbox {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.contact-form__checkbox input {
  width: auto;
  margin: 0.25rem 0 0;
  flex-shrink: 0;
}

.contact-form__checkbox label {
  margin-bottom: 0;
  font-weight: 400;
  color: var(--grey);
  font-size: 0.9rem;
}

.contact-form__success {
  display: none;
  padding: 1rem;
  background: rgba(201, 168, 76, 0.15);
  border: 1px solid var(--gold);
  color: var(--gold-light);
  margin-bottom: 1rem;
}

.contact-form__success.is-visible {
  display: block;
}

.contact-info__address,
.contact-info__meeting {
  margin-bottom: 1.5rem;
}

.contact-info h3 {
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.contact-info p {
  color: var(--grey);
  font-size: 0.95rem;
}

.contact-info__quote {
  margin: 2rem 0;
  padding-left: 1.25rem;
  border-left: 3px solid var(--gold);
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  font-style: italic;
  color: var(--gold-light);
}

.contact-map {
  margin-top: 2rem;
  width: 100%;
  height: 280px;
  border: 1px solid rgba(201, 168, 76, 0.2);
}

.contact-map iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* ============================================
   Members Page
   ============================================ */

.members-gate {
  max-width: 400px;
  margin: 2rem auto 3rem;
  padding: 2rem;
  background: var(--navy-mid);
  border: 1px solid rgba(201, 168, 76, 0.2);
}

.members-gate label {
  display: block;
  font-size: 0.9rem;
  margin-bottom: 0.5rem;
  color: var(--white);
}

.members-gate input {
  width: 100%;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  font-family: 'Jost', sans-serif;
  font-size: 1rem;
  color: var(--white);
  background: var(--navy);
  border: 1px solid rgba(201, 168, 76, 0.25);
}

.members-gate input:focus {
  outline: none;
  border-color: var(--gold);
}

.members-gate__error {
  display: none;
  color: #c75c5c;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.members-gate__error.is-visible {
  display: block;
}

.members-content {
  padding: 2rem 0;
}

.members-links {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

.members-links .card {
  padding: 1.5rem;
}

.members-links .card a {
  color: var(--white);
  font-weight: 500;
}

.members-links .card a:hover {
  color: var(--gold-light);
}

.members-note {
  font-size: 0.9rem;
  color: var(--grey);
  text-align: center;
  padding-top: 1rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(201, 168, 76, 0.1);
}

.members-section {
  margin-bottom: 2.5rem;
}

.members-section:last-of-type {
  margin-bottom: 0;
}

.members-section__heading {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 2.5vw, 2rem);
  font-weight: 600;
  color: var(--gold);
  margin-bottom: 0.35rem;
}

.members-section__subheading {
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
  color: var(--grey);
  margin-bottom: 0.75rem;
}

.members-section__divider {
  width: 4rem;
  height: 2px;
  background: var(--gold);
  margin-bottom: 1.25rem;
}

.members-section__img {
  max-width: 180px;
  width: 100%;
  height: auto;
  margin-bottom: 1.5rem;
}

.members-table-wrap {
  overflow-x: auto;
}

.members-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
}

.members-table th,
.members-table td {
  padding: 0.6rem 0.75rem;
  text-align: left;
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
}

.members-table th {
  font-family: var(--font-serif);
  font-weight: 600;
  color: var(--gold);
  background: var(--navy-mid);
}

.members-table tbody tr:nth-child(even) {
  background: var(--navy-light);
}

.members-table tbody tr:nth-child(odd) {
  background: transparent;
}

.members-table td {
  color: var(--white);
}

.members-table__name {
  font-family: var(--font-serif);
}

.members-hr {
  border: none;
  height: 1px;
  background: var(--gold);
  margin: 2.5rem 0;
}

.past-masters-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem 1.5rem;
}

.past-masters-item {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
  font-family: 'Jost', sans-serif;
  font-size: 0.9rem;
}

.past-masters-year {
  flex-shrink: 0;
  color: var(--gold);
  font-weight: 500;
}

.past-masters-name {
  color: var(--white);
}

.content-section__intro {
  margin-bottom: 1rem;
}

.members-list {
  padding: 1.5rem 1.75rem;
}

.members-list__placeholder {
  color: var(--grey);
  font-weight: 300;
  margin: 0;
}

.members-list__names {
  list-style: none;
  margin: 1rem 0 0;
  padding: 0;
}

.members-list__names li {
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(201, 168, 76, 0.1);
  color: var(--white);
  font-weight: 400;
}

.members-list__names li:last-child {
  border-bottom: none;
}

/* ============================================
   News Grid
   ============================================ */

.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.5rem;
}

/* News full articles (with image and body) */
.news-article {
  margin-bottom: 3rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(201, 168, 76, 0.15);
}

.news-article:last-child {
  border-bottom: none;
  margin-bottom: 0;
  padding-bottom: 0;
}

.news-article__date {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.05em;
  margin-bottom: 0.35rem;
}

.news-article__title {
  font-family: var(--font-serif);
  font-size: clamp(1.25rem, 2vw, 1.6rem);
  font-weight: 600;
  color: var(--gold);
  margin-bottom: 0.75rem;
  line-height: 1.3;
}

.news-article__img {
  display: block;
  max-width: 700px;
  width: 100%;
  margin: 2rem auto;
  border: 2px solid rgba(201, 168, 76, 0.3);
}

.news-article img,
.news-content img,
article img {
  display: block;
  max-width: 700px;
  width: 100%;
  margin: 2rem auto;
  border: 2px solid rgba(201, 168, 76, 0.3);
}

.news-article__body {
  font-family: 'Jost', sans-serif;
  font-size: 0.95rem;
  line-height: 1.65;
  color: var(--grey);
  font-weight: 300;
}

.news-article__body p {
  margin-bottom: 1rem;
}

.news-article__body p:last-child {
  margin-bottom: 0;
}

.news-intro {
  text-align: center;
  margin-bottom: 2.5rem;
}

.news-intro h2 {
  font-family: var(--font-serif);
  color: var(--gold);
  margin-bottom: 0.5rem;
}

.news-intro p {
  color: var(--grey);
  font-size: 1rem;
}

/* ============================================
   Responsive
   ============================================ */

@media (max-width: 900px) {
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .values .container {
    grid-template-columns: 1fr;
  }

  .members-links {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 600px) {
  .nav__links {
    position: fixed;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: rgba(10, 15, 30, 0.98);
    backdrop-filter: blur(12px);
    flex-direction: column;
    padding: 2rem;
    gap: 1.5rem;
    border-bottom: 1px solid rgba(201, 168, 76, 0.15);
    transform: translateY(-100%);
    opacity: 0;
    visibility: hidden;
    transition: transform var(--transition), opacity var(--transition), visibility var(--transition);
  }

  .nav__links.is-open {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
  }

  .nav.is-shrunk .nav__links {
    top: var(--nav-height-shrink);
  }

  .nav__toggle {
    display: flex;
  }

  .hero {
    padding: calc(var(--nav-height) + 2rem) 1rem 3rem;
  }

  .hero__ctas {
    flex-direction: column;
  }

  .hero__ctas .btn {
    width: 100%;
  }

  .stats .container {
    flex-direction: column;
    gap: 1.5rem;
  }

  .footer .container {
    flex-direction: column;
    text-align: center;
  }

  .footer__nav {
    justify-content: center;
  }

  .section {
    padding: 3rem 1rem;
  }

  .page-hero {
    padding: calc(var(--nav-height) + 3rem) 1rem 2rem;
  }

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

  .past-masters-grid {
    grid-template-columns: 1fr;
  }
}
