/* ════════════════════════════════════════
   CONTACT.CSS — Milky Way Web Studio
   Requires: tokens.css
   Sections: hero, features, calendar, contact form
   ════════════════════════════════════════ */

/* ════════════════════════════════════════
   SEMANTIC TOKENS — contact page
   Bridge: maps primitive tokens →
   local token names this page uses.
   ════════════════════════════════════════ */
:root,
[data-theme="light"] {
  --clr-text-white:      var(--clr-text-white-always);
  --clr-text-medium:     var(--clr-text-medium-always);
  --clr-text-dark:       var(--clr-text-dark-always);
  --clr-btn-shadow-blue: var(--clr-shadow-blue);
}

/* ===================================
   RESET & BASE
=================================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  overscroll-behavior: none;
}

body {
  font-family: 'DM Sans', var(--font-family);
  font-weight: 300;
  line-height: var(--line-height);
  background: var(--clr-bg);
  color: var(--clr-text-body);
}

a { text-decoration: none; }

/* ===================================
   SECTION 1 — HERO
=================================== */
#hero-section {
  background: var(--clr-bg-hero);
  padding: 4.5rem 2rem 3.5rem;
}

.hero-inner {
  max-width: 960px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 3.5rem;
  align-items: center;
}

.hero-tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--clr-brand-blue-dk);
  border-radius: 100px;
  padding: 5px 16px;
  margin-bottom: 1.2rem;
}

#hero-section h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 4.5vw, 3rem);
  line-height: 1.15;
  letter-spacing: -0.01em;
  color: var(--clr-brand-blue-dk);
  margin-bottom: 1.1rem;
}

#hero-section h1 em {
  font-style: italic;
  color: var(--clr-brand-orange);
}

#hero-section p {
  font-size: 1rem;
  color: var(--clr-text-body);
  line-height: 1.8;
  margin-bottom: 2rem;
  max-width: 480px;
}

.hero-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--clr-brand-blue-dk);
  color: var(--clr-text-white);
  font-size: 0.9rem;
  font-weight: 400;
  padding: 13px 28px;
  border-radius: 6px;
  letter-spacing: 0.02em;
  transition: background 0.2s, transform 0.15s;
  box-shadow: 0 4px 14px var(--clr-btn-shadow-blue);
}

.hero-cta:hover {
  background: var(--clr-brand-blue);
  transform: translateY(-2px);
}

.hero-cta svg { transition: transform 0.2s; }
.hero-cta:hover svg { transform: translateX(3px); }

/* ===================================
   PROFILE CARD
=================================== */
.profile-card {
  background: var(--clr-footer-bg);
  border: 1.5px solid var(--clr-brand-blue);
  border-radius: 16px;
  padding: 2rem 1.5rem;
  text-align: center;
  box-shadow: 0 8px 32px var(--clr-shadow-lg);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.profile-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 70px;
  background: linear-gradient(135deg, var(--clr-brand-blue-dk), var(--clr-brand-blue));
}

.profile-avatar {
  position: relative;
  width: 7.8rem;
  height: 7.8rem;
  border-radius: 50%;
  background: var(--clr-brand-blue-dk);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0.75rem auto 1.1rem;
  border: 3px solid var(--clr-footer-bg);
  overflow: hidden;
  box-shadow: 0 4px 12px var(--clr-btn-shadow-blue);
  transform: translateY(-1.25rem);
}

.profile-avatar img {
  width: 7.2rem;
  height: 7.2rem;
  object-fit: contain;
}

/* Restore color and z-index together so the ::before gradient
   overlay doesn't sit on top of the text */
.profile-card .profile-name,
.profile-card .profile-role,
.profile-card .profile-bio {
  color: var(--clr-text-white) !important;
  position: relative;
  z-index: 2;
}

.profile-name {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  margin-bottom: 4px;
}

.profile-role {
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.profile-bio {
  font-size: 0.84rem;
  line-height: 1.7;
  margin-bottom: 1.25rem;
}

.profile-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.stat-box {
  background: var(--clr-footer-border);
  border-radius: 8px;
  padding: 10px 8px;
  border: 1px solid hsla(204, 64%, 52%, 0.2);
}

.stat-num {
  font-family: 'Playfair Display', serif;
  font-size: 1.3rem;
  letter-spacing: .1rem;
  color: var(--clr-brand-orange);
  text-shadow: 0 0 1px var(--clr-text-white);
  display: block;
}

.stat-lbl {
  font-size: 0.7rem;
  color: var(--clr-text-medium);
  text-transform: uppercase;
  letter-spacing: 0.07em;
}

/* ===================================
   SECTION 2 — FEATURES
=================================== */
#second-section {
  padding: 0 2rem;
}

.section-divider {
  max-width: 960px;
  margin: 3rem auto 0;
  padding: 0 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  color: var(--clr-text-muted);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.section-divider::before,
.section-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--clr-border);
}

.features {
  max-width: 960px;
  margin: 1.5rem auto 0;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
}

.feature {
  background: var(--clr-bg-surface);
  border: 1px solid var(--clr-border);
  border-top: 3px solid var(--clr-brand-blue);
  border-radius: 10px;
  padding: 1.5rem;
  transition: box-shadow 0.2s, transform 0.2s;
}

.feature:hover {
  box-shadow: 0 6px 20px var(--clr-btn-shadow-blue);
  transform: translateY(-3px);
}

.feature-icon { font-size: 1.5rem; margin-bottom: 0.75rem; }

.feature h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1rem;
  color: var(--clr-brand-blue-dk);
  margin-bottom: 6px;
  font-weight: 600;
}

.feature p {
  font-size: 0.84rem;
  color: var(--clr-text-body);
  line-height: 1.65;
}

/* ===================================
   SECTION 3 — CALENDAR WIDGET
=================================== */
#third-section {
  max-width: 960px;
  margin: 3rem auto 0;
  padding: 0 2rem;
}

.mww-widget {
  display: flex;
  background: #ffffff;
  border-radius: 20px;
  overflow: hidden;
  box-shadow: 0 4px 40px rgba(0,0,0,0.08);
  width: 100%;
  margin: 0 auto;
  font-family: 'DM Sans', sans-serif;
}

.mww-left {
  width: 300px;
  flex-shrink: 0;
  padding: 2.5rem 2rem;
  border-right: 1px solid #ebebeb;
}

.mww-host-name {
  font-size: 0.85rem;
  font-weight: 500;
  color: #7b7b8a;
  margin-bottom: 0.4rem;
  letter-spacing: 0.01em;
}

.mww-event-title {
  font-family: 'DM Serif Display', serif;
  font-size: 1.75rem;
  color: #1a1a2e;
  line-height: 1.2;
  margin-bottom: 1rem;
}

.mww-event-desc {
  font-size: 0.875rem;
  color: #4a4a5a;
  line-height: 1.65;
  margin-bottom: 1.75rem;
}

.mww-meta-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  padding: 0;
}

.mww-meta-list li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.875rem;
  color: #4a4a5a;
}

.mww-meta-list li svg {
  flex-shrink: 0;
  opacity: 0.6;
}

.mww-right {
  flex: 1;
  padding: 2.5rem 2.5rem 2rem;
}

.mww-cal-header {
  display: flex;
  align-items: baseline;
  gap: 0.5rem;
  margin-bottom: 2rem;
}

.mww-cal-month {
  font-family: 'DM Serif Display', serif;
  font-size: 1.6rem;
  color: #1a1a2e;
}

.mww-cal-year {
  font-size: 1.6rem;
  color: #b0b0be;
  font-weight: 300;
}

.mww-cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
}

.mww-day-header {
  text-align: center;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  color: #adadbe;
  padding-bottom: 0.75rem;
  text-transform: uppercase;
}

.mww-day-cell {
  position: relative;
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  color: #c0c0cc;
  border-radius: 10px;
  cursor: default;
  user-select: none;
}

.mww-day-cell.available {
  background: #f0eff4;
  color: #1a1a2e;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.18s, transform 0.15s;
}

.mww-day-cell.available:hover {
  background: #e0dff0;
  transform: scale(1.06);
}

.mww-day-cell.today-dot::after {
  content: '';
  position: absolute;
  bottom: 5px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #6c6caa;
}

.mww-day-cell.blank-cell {
  background: #f0eff4;
  border-radius: 10px;
}

.mww-day-cell.other-month {
  color: #9090b0;
  font-size: 0.8rem;
}

.mww-day-cell.other-month.available {
  background: #f7f7fb;
}

.mww-month-label {
  font-size: 0.6rem;
  font-weight: 700;
  letter-spacing: 0.07em;
  color: #aaaacc;
  text-transform: uppercase;
  position: absolute;
  top: 5px;
  left: 0;
  right: 0;
  text-align: center;
  line-height: 1;
}

/* ===================================
   SECTION 4 — CONTACT FORM
=================================== */
#fourth-section {
  background: var(--clr-footer-bg);
  margin-top: 3.5rem;
  padding: 3.5rem 2rem;
}

.contact-inner {
  max-width: 960px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3rem;
  align-items: start;
}

.contact-left h2 {
  font-family: 'Playfair Display', serif;
  font-size: 1.8rem;
  color: var(--clr-text-white);
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}

.contact-left h2 em {
  font-style: italic;
  color: var(--clr-brand-orange);
}

.contact-left p {
  font-size: 0.92rem;
  color: var(--clr-text-medium);
  line-height: 1.75;
  margin-bottom: 2rem;
}

.contact-buttons {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.contact-btn {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--clr-footer-border);
  border: 1px solid hsla(204, 64%, 52%, 0.25);
  border-radius: 10px;
  padding: 14px 3px;
  /* padding: 14px 18px; */
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.contact-btn:hover {
  background: var(--clr-brand-blue-dk);
  border-color: var(--clr-brand-blue);
  transform: translateX(4px);
}

.contact-btn img {
  width: 44px;
  height: 44px;
  object-fit: contain;
  flex-shrink: 0;
}

.contact-btn-text strong {
  display: block;
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--clr-text-white);
  margin-bottom: 2px;
}

.contact-btn-text span {
  font-size: 0.78rem;
  color: var(--clr-text-medium);
}

/* ===================================
   MESSAGE FORM
=================================== */
.contact-form {
  background: var(--clr-bg-surface);
  border-radius: 12px;
  padding: 2rem;
  border: 1px solid var(--clr-border);
  border-top: 3px solid var(--clr-brand-blue);
  position: relative;
  overflow: hidden;
}

.contact-form h3 {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  color: var(--clr-brand-blue-dk);
  margin-bottom: 1.25rem;
}

.form-group { margin-bottom: 14px; }

.form-group label {
  display: block;
  font-size: 0.78rem;
  font-weight: 500;
  color: var(--clr-text-dark);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 6px;
}

.form-group input,
.form-group textarea {
  width: 100%;
  padding: 10px 14px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.9rem;
  font-weight: 300;
  color: var(--clr-text-heading);
  background: var(--clr-bg);
  border: 1px solid var(--clr-border);
  border-radius: 7px;
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
  resize: none;
  caret-color: var(--clr-brand-orange-dk);
  caret-shape: block;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--clr-brand-green);
  box-shadow: 0 0 0 3px var(--clr-btn-shadow-blue);
}

.form-group textarea { height: 120px; }

.send-btn {
  width: 100%;
  padding: 12px;
  background: var(--clr-brand-blue-dk);
  color: var(--clr-text-white);
  border: none;
  border-radius: 7px;
  font-family: 'DM Sans', sans-serif;
  font-size: 0.95rem;
  font-weight: 400;
  letter-spacing: 0.03em;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  margin-top: 4px;
}

.send-btn:hover {
  background: var(--clr-brand-blue);
  transform: translateY(-1px);
}
.glider-overlay {
  position: absolute;
  inset: 0;
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: var(--clr-bg-surface);
  z-index: 5;
}

.glider-overlay.show {
  display: flex;
}

.glider-img {
  width: 80px;
  height: 80px;
  object-fit: contain;
  animation: glider-fly 1.1s ease-out forwards;
}

.glider-text {
  font-family: 'Playfair Display', serif;
  font-size: 1.1rem;
  color: var(--clr-brand-blue-dk);
  opacity: 0;
  animation: glider-text-in 0.5s ease-out 0.6s forwards;
}

@keyframes glider-fly {
  0%   { transform: translate(-120px, 40px) rotate(-25deg); opacity: 0; }
  30%  { opacity: 1; }
  100% { transform: translate(0, 0) rotate(0deg); opacity: 1; }
}

@keyframes glider-text-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ===================================
   INTERSECTION OBSERVER ANIMATIONS
   The IO in intersection-observer.js adds
   'fade-in' to each section when it scrolls
   into view. These styles define the before
   (hidden) and after (visible) states.
=================================== */
#second-section,
#third-section,
#fourth-section {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in {
  opacity: 1 !important;
  transform: translateY(0) !important;
}

/* ===================================
   RESPONSIVE
=================================== */
@media (max-width: 860px) {
  .mww-widget { margin: 0; width: auto; }
}

@media (max-width: 700px) {
  .hero-inner    { grid-template-columns: 1fr; }
  .profile-card  { display: none; }
  .features      { grid-template-columns: 1fr; }
  .contact-inner { grid-template-columns: 1fr; }
  .mww-widget    { flex-direction: column; border-radius: 12px; }
  .mww-left      { width: 100%; border-right: none; border-bottom: 1px solid #ebebeb; padding: 1.75rem 1.5rem; }
  .mww-right     { padding: 1.5rem; }
}
@media (width < 400px) {
  #second-section {
    padding-left: 5px;
    padding-right: 5px;
  }

  .section-divider {
    padding-left: 5px;
    padding-right: 5px;
  }

  .features {
    padding-left: 5px;
    padding-right: 5px;
  }

  #third-section {
    padding-left: 5px;
    padding-right: 5px;
  }

  .mww-left {
    padding: 1.5rem 5px;
  }

 .mww-right {
  padding: 1rem 5px;
}

 .mww-cal-grid {
  gap: 2px;
}

 .mww-day-header,
.mww-day-cell {
  font-size: 0.72rem;
}
.mww-month-label {
  font-size: 0.45rem;
}

  .mww-cal-header {
    margin-bottom: 1rem;
  }

  .contact-left {
  padding-left: 5px;
  padding-right: 5px;
}
  #fourth-section {
    padding-left: 5px;
    padding-right: 5px;
  }

  .contact-form {
    padding: 1rem 5px;
  }

  .contact-inner {
    gap: 1.5rem;
  }
}

/* ===================================
   DARK MODE OVERRIDES
=================================== */
@media (prefers-color-scheme: dark) {

  .form-group label {
    color: hsl(0, 0%, 100%) !important;
  }

  .form-group input,
  .form-group textarea {
    color: hsl(0, 0%, 100%) !important;
    background: hsl(0, 0%, 20%) !important;
    border-color: hsl(0, 0%, 40%) !important;
  }

  .form-group input::placeholder,
  .form-group textarea::placeholder {
    color: hsl(0, 0%, 75%) !important;
  }
}

/* ALWAYS LAST */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
