/* ==========================================================================
   Gaharwar Group — stylesheet
   Palette: deep maroon #690000 / warm ivory #F4E8E5
   ========================================================================== */

:root {
  --maroon: #690000;
  --maroon-deep: #4a0000;
  --maroon-dark: #2e0000;
  --ivory: #f4e8e5;
  --ivory-dim: rgba(244, 232, 229, 0.72);
  --ivory-faint: rgba(244, 232, 229, 0.42);
  --line: rgba(244, 232, 229, 0.16);
  --line-strong: rgba(244, 232, 229, 0.3);
  --panel: rgba(46, 0, 0, 0.55);
  --panel-solid: rgba(46, 0, 0, 0.78);

  --font-display: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --font-body: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;

  --header-h: 82px;
  --radius: 4px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);

  /* Hide the scrollbar while keeping the page scrollable */
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* legacy Edge / IE */
}

html::-webkit-scrollbar,
body::-webkit-scrollbar {
  width: 0;
  height: 0;
  display: none; /* Chrome, Edge, Safari */
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 300;
  font-size: 16px;
  line-height: 1.7;
  color: var(--ivory);
  background-color: var(--maroon-dark);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

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

::selection {
  background: var(--ivory);
  color: var(--maroon);
}

/* --------------------------------------------------------------------------
   Background layers
   -------------------------------------------------------------------------- */

/* The wallpaper is 3344 x 1882 (16:9). `contain` shows the whole image instead of
   cropping into it, so it reads as much less zoomed on wide screens. Any leftover
   space falls back to the deep maroon base, which the overlay blends into. */
.bg-layer {
  position: fixed;
  inset: 0;
  overflow: hidden;
  background-color: var(--maroon-dark);
  z-index: -2;
}

/* Blurred filler layer: fills the viewport so the edges of the sharp `contain`
   image melt into the background instead of ending in a hard rectangle. */
.bg-layer::before {
  content: "";
  position: absolute;
  inset: -7%;
  background-image: url("asset/background_web.webp");
  background-size: cover;
  background-position: center center;
  background-repeat: no-repeat;
  filter: blur(48px) saturate(0.85);
  opacity: 0.6;
}

/* Sharp layer: the whole wallpaper, uncropped. */
.bg-layer::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("asset/background_web.webp");
  background-size: contain;
  background-position: center center;
  background-repeat: no-repeat;
}

/* On tall/narrow screens `contain` would shrink a 16:9 image to a thin strip,
   so fill the viewport there instead. */
@media (max-aspect-ratio: 4 / 3) {
  .bg-layer::before {
    display: none;
  }

  .bg-layer::after {
    background-size: cover;
  }
}

.bg-overlay {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(105, 0, 0, 0.55) 0%, rgba(46, 0, 0, 0.88) 70%, rgba(20, 0, 0, 0.95) 100%),
    linear-gradient(180deg, rgba(105, 0, 0, 0.6) 0%, rgba(74, 0, 0, 0.82) 100%);
}

/* --------------------------------------------------------------------------
   Layout helpers
   -------------------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: 1160px;
  margin: 0 auto;
  padding: 0 28px;
}

.section {
  position: relative;
  padding: 110px 0;
}

.section-alt {
  background: linear-gradient(180deg, rgba(46, 0, 0, 0.35) 0%, rgba(46, 0, 0, 0.6) 100%);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.section-head {
  max-width: 720px;
  margin-bottom: 56px;
}

.section-kicker {
  display: inline-block;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ivory-faint);
  margin-bottom: 14px;
}

.section-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 4.4vw, 3.1rem);
  line-height: 1.12;
  margin: 0 0 18px;
  letter-spacing: -0.01em;
}

.section-title::after {
  content: "";
  display: block;
  width: 62px;
  height: 2px;
  margin-top: 22px;
  background: var(--ivory);
  opacity: 0.75;
}

.section-lead {
  margin: 0;
  color: var(--ivory-dim);
  font-size: 1.05rem;
  max-width: 56ch;
}

/* --------------------------------------------------------------------------
   Header
   -------------------------------------------------------------------------- */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  transition: background-color 0.35s var(--ease), backdrop-filter 0.35s var(--ease),
    border-color 0.35s var(--ease), height 0.35s var(--ease);
  border-bottom: 1px solid transparent;
}

.site-header.is-scrolled {
  height: 66px;
  background: rgba(46, 0, 0, 0.9);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom-color: var(--line);
}

/* The header spans the full viewport width so the brand sits hard left and the
   nav hard right, rather than being boxed in by the shared container max-width. */
.site-header .header-inner {
  max-width: none;
  width: 100%;
  padding: 0 clamp(20px, 3.2vw, 52px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.brand-logo {
  height: 44px;
  width: auto;
  transition: height 0.35s var(--ease);
}

.site-header.is-scrolled .brand-logo {
  height: 36px;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
  min-width: 0;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.32rem;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.brand-tagline {
  font-size: 0.62rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ivory-faint);
  white-space: nowrap;
}

/* Nav */
.nav-list {
  display: flex;
  align-items: center;
  gap: 34px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-link {
  position: relative;
  font-size: 0.82rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  font-weight: 400;
  color: var(--ivory-dim);
  padding: 6px 0;
  transition: color 0.25s var(--ease);
}

.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 1px;
  width: 0;
  background: var(--ivory);
  transition: width 0.3s var(--ease);
}

.nav-link:hover,
.nav-link:focus-visible,
.nav-link.is-active {
  color: var(--ivory);
}

.nav-link:hover::after,
.nav-link:focus-visible::after,
.nav-link.is-active::after {
  width: 100%;
}

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 44px;
  height: 44px;
  padding: 0;
  background: none;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 1.5px;
  width: 20px;
  margin: 0 auto;
  background: var(--ivory);
  transition: transform 0.3s var(--ease), opacity 0.2s var(--ease);
}

.nav-toggle.is-open span:nth-child(1) {
  transform: translateY(7.5px) rotate(45deg);
}
.nav-toggle.is-open span:nth-child(2) {
  opacity: 0;
}
.nav-toggle.is-open span:nth-child(3) {
  transform: translateY(-7.5px) rotate(-45deg);
}

/* --------------------------------------------------------------------------
   Buttons
   -------------------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 34px;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  border-radius: var(--radius);
  border: 1px solid var(--ivory);
  cursor: pointer;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease),
    transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.btn-primary {
  background: var(--ivory);
  color: var(--maroon);
}

.btn-primary:hover {
  background: transparent;
  color: var(--ivory);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.32);
}

.btn-ghost {
  background: transparent;
  color: var(--ivory);
  border-color: var(--line-strong);
}

.btn-ghost:hover {
  border-color: var(--ivory);
  background: rgba(244, 232, 229, 0.08);
  transform: translateY(-2px);
}

.btn-block {
  width: 100%;
}

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: calc(var(--header-h) + 40px) 0 90px;
}

.hero-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.hero-logo {
  height: 108px;
  width: auto;
  margin-bottom: 30px;
  filter: drop-shadow(0 10px 26px rgba(0, 0, 0, 0.45));
}

.hero-eyebrow {
  margin: 0 0 16px;
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ivory-faint);
}

.hero-title {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(2.9rem, 9vw, 6.2rem);
  line-height: 1.02;
  letter-spacing: -0.015em;
  margin: 0 0 26px;
  text-shadow: 0 14px 40px rgba(0, 0, 0, 0.45);
}

.hero-sub {
  margin: 0 auto 40px;
  max-width: 60ch;
  font-size: clamp(1rem, 1.6vw, 1.14rem);
  color: var(--ivory-dim);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.scroll-cue {
  position: absolute;
  bottom: 34px;
  left: 50%;
  transform: translateX(-50%);
  width: 24px;
  height: 52px;
  display: flex;
  justify-content: center;
}

.scroll-cue-line {
  width: 1px;
  height: 100%;
  background: linear-gradient(180deg, transparent, var(--ivory));
  animation: cue 2.2s var(--ease) infinite;
  transform-origin: top;
}

@keyframes cue {
  0% { transform: scaleY(0); opacity: 0; }
  40% { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1); opacity: 0; }
}

/* --------------------------------------------------------------------------
   About
   -------------------------------------------------------------------------- */

.about-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 64px;
  align-items: start;
}

.about-copy p {
  margin: 0 0 20px;
  font-size: 1.05rem;
  color: var(--ivory-dim);
}

.about-copy p:last-child {
  margin-bottom: 0;
}

.stat-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.stat {
  background: var(--panel);
  padding: 30px 22px;
  text-align: center;
}

.stat-num,
.stat-suffix {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 2.5rem;
  line-height: 1;
}

.stat-suffix {
  font-size: 1.6rem;
}

.stat-label {
  display: block;
  margin-top: 10px;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ivory-faint);
}

/* --------------------------------------------------------------------------
   Cards (ventures)
   -------------------------------------------------------------------------- */

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(290px, 1fr));
  gap: 22px;
}

.card {
  position: relative;
  padding: 38px 30px 34px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  transition: transform 0.4s var(--ease), border-color 0.4s var(--ease),
    background-color 0.4s var(--ease), box-shadow 0.4s var(--ease);
}

.card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--ivory);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.45s var(--ease);
}

.card:hover {
  transform: translateY(-6px);
  border-color: var(--line-strong);
  background: var(--panel-solid);
  box-shadow: 0 22px 46px rgba(0, 0, 0, 0.36);
}

.card:hover::before {
  transform: scaleX(1);
}

.card-index {
  display: block;
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: 0.14em;
  color: var(--ivory-faint);
  margin-bottom: 16px;
}

.card-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.45rem;
  line-height: 1.25;
  margin: 0 0 12px;
}

.card-text {
  margin: 0;
  font-size: 0.95rem;
  color: var(--ivory-dim);
}

/* --------------------------------------------------------------------------
   Values
   -------------------------------------------------------------------------- */

.value-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 40px 34px;
}

.value {
  padding-left: 22px;
  border-left: 2px solid var(--line-strong);
  transition: border-color 0.3s var(--ease);
}

.value:hover {
  border-left-color: var(--ivory);
}

.value-title {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.3rem;
  margin: 0 0 10px;
}

.value-text {
  margin: 0;
  font-size: 0.95rem;
  color: var(--ivory-dim);
}

/* --------------------------------------------------------------------------
   Contact
   -------------------------------------------------------------------------- */

.contact-grid {
  display: grid;
  grid-template-columns: 0.85fr 1.15fr;
  gap: 60px;
  align-items: start;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  transition: padding-left 0.3s var(--ease);
}

.contact-item:first-child {
  padding-top: 0;
}

a.contact-item:hover {
  padding-left: 8px;
}

.contact-icon {
  width: 30px;
  height: 30px;
  object-fit: contain;
  flex-shrink: 0;
}

.contact-icon-dot {
  display: block;
  width: 8px;
  height: 8px;
  margin: 0 11px;
  border-radius: 50%;
  background: var(--ivory);
  opacity: 0.6;
}

.contact-label {
  display: block;
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ivory-faint);
}

.contact-value {
  display: block;
  font-size: 1rem;
}

/* Form */
.contact-form {
  padding: 36px 32px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.field {
  margin-bottom: 20px;
}

.field label {
  display: block;
  margin-bottom: 8px;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ivory-faint);
}

.field input,
.field textarea {
  width: 100%;
  padding: 13px 15px;
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 300;
  color: var(--ivory);
  background: rgba(20, 0, 0, 0.45);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  outline: none;
  resize: vertical;
  transition: border-color 0.25s var(--ease), background-color 0.25s var(--ease);
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--ivory-faint);
}

.field input:focus,
.field textarea:focus {
  border-color: var(--ivory);
  background: rgba(20, 0, 0, 0.66);
}

.field.has-error input,
.field.has-error textarea {
  border-color: #ff9d9d;
}

.field-error {
  display: block;
  min-height: 16px;
  margin-top: 6px;
  font-size: 0.75rem;
  color: #ffb3b3;
}

.form-status {
  margin: 16px 0 0;
  min-height: 20px;
  font-size: 0.88rem;
  text-align: center;
  color: var(--ivory-dim);
}

/* --------------------------------------------------------------------------
   Footer
   -------------------------------------------------------------------------- */

.site-footer {
  padding: 40px 0;
  background: rgba(20, 0, 0, 0.82);
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
}

.footer-logo {
  height: 34px;
  width: auto;
}

.footer-note {
  margin: 0;
  font-size: 0.82rem;
  color: var(--ivory-faint);
}

/* --------------------------------------------------------------------------
   Back to top
   -------------------------------------------------------------------------- */

.to-top {
  position: fixed;
  right: 26px;
  bottom: 26px;
  z-index: 90;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  font-size: 1.05rem;
  color: var(--ivory);
  background: rgba(105, 0, 0, 0.85);
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease),
    visibility 0.3s var(--ease), background-color 0.3s var(--ease);
}

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

.to-top:hover {
  background: var(--ivory);
  color: var(--maroon);
}

/* --------------------------------------------------------------------------
   Reveal on scroll
   -------------------------------------------------------------------------- */

.reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.75s var(--ease), transform 0.75s var(--ease);
}

.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* --------------------------------------------------------------------------
   Focus visibility
   -------------------------------------------------------------------------- */

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid var(--ivory);
  outline-offset: 3px;
}

/* --------------------------------------------------------------------------
   Responsive
   -------------------------------------------------------------------------- */

@media (max-width: 960px) {
  .about-grid,
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 44px;
  }
}

@media (max-width: 820px) {
  .nav-toggle {
    display: flex;
  }

  /* Anchored to the header (its fixed parent) so it stays flush when the
     header shrinks on scroll. */
  .nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(46, 0, 0, 0.97);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s var(--ease);
  }

  .nav.is-open {
    max-height: 340px;
  }

  /* Matches the header's horizontal padding so drawer links line up with the logo. */
  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    padding: 8px clamp(20px, 3.2vw, 52px) 22px;
  }

  .nav-list li {
    border-bottom: 1px solid var(--line);
  }

  .nav-list li:last-child {
    border-bottom: none;
  }

  .nav-link {
    display: block;
    padding: 16px 0;
  }

  .nav-link::after {
    display: none;
  }

  .brand-tagline {
    display: none;
  }

  .section {
    padding: 80px 0;
  }

  .hero-logo {
    height: 88px;
  }
}

@media (max-width: 560px) {
  .container {
    padding: 0 20px;
  }

  .brand-name {
    font-size: 1.1rem;
  }

  .stat-list {
    grid-template-columns: 1fr;
  }

  .contact-form {
    padding: 26px 20px;
  }

  .btn {
    padding: 14px 26px;
  }

  .hero-actions {
    width: 100%;
    flex-direction: column;
  }

  .hero-actions .btn {
    width: 100%;
  }

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

/* --------------------------------------------------------------------------
   Reduced motion
   -------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
