/* tanso.in — glassmorphic hexagonal honeycomb, duotone teal/gold, Indian cultural lens */

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

:root {
  --teal: #0a3a3e;
  --teal-deep: #0a1e20;
  --gold: #c4a040;
  --saffron: #e88a30;
  --ivory: #f0e8d4;
  --jade: #3a8a6a;
  --glass: rgba(255, 255, 255, 0.15);
  --glass-border: rgba(255, 255, 255, 0.22);
  --glass-strong: rgba(255, 255, 255, 0.25);
}

html, body {
  background: var(--teal-deep);
  color: var(--ivory);
  font-family: 'Inter', system-ui, sans-serif;
  font-size: clamp(15px, 1.5vw, 18px);
  line-height: 1.75;
  overflow-x: hidden;
}

body {
  min-height: 100vh;
}

/* ---------- Jali pattern overlay (background texture) ---------- */
.jali-pattern {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  background-image:
    repeating-linear-gradient(60deg, rgba(196,160,64,0.04) 0 1px, transparent 1px 28px),
    repeating-linear-gradient(-60deg, rgba(196,160,64,0.04) 0 1px, transparent 1px 28px),
    repeating-linear-gradient(0deg, rgba(196,160,64,0.04) 0 1px, transparent 1px 28px);
  mix-blend-mode: screen;
}

/* ---------- Opening viewport ---------- */
.opening {
  position: relative;
  height: 100vh;
  min-height: 640px;
  display: grid;
  place-items: center;
  overflow: hidden;
  isolation: isolate;
}

.duotone-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse at 30% 20%, rgba(196,160,64,0.45), transparent 55%),
    radial-gradient(ellipse at 70% 80%, rgba(58,138,106,0.35), transparent 60%),
    linear-gradient(135deg, #0a3a3e 0%, #0a1e20 60%, #1c2a2c 100%);
  z-index: -2;
}

.duotone-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 18% 28%, rgba(232,138,48,0.18), transparent 35%),
    radial-gradient(circle at 82% 72%, rgba(196,160,64,0.18), transparent 40%);
  mix-blend-mode: overlay;
}

.hex-center {
  position: relative;
  width: clamp(280px, 56vw, 560px);
  aspect-ratio: 1 / 0.866;
  display: grid;
  place-items: center;
  z-index: 3;
  opacity: 0;
  transform: scale(0.96);
  animation: hexEnter 1.4s cubic-bezier(.2,.7,.2,1) 0.25s forwards;
}

.hex-center::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--glass);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  border: 1px solid var(--glass-border);
  z-index: -1;
}

.hex-center::after {
  content: "";
  position: absolute;
  inset: 0;
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  background: linear-gradient(135deg, rgba(255,255,255,0.06), rgba(196,160,64,0.04));
  pointer-events: none;
}

.hex-inner {
  text-align: center;
  padding: 2rem 2.5rem;
  max-width: 78%;
}

.hex-eyebrow {
  font-family: 'DM Sans', 'Inter', sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.32em;
  color: var(--gold);
  margin-bottom: 1.4rem;
  text-transform: uppercase;
}

.hex-title {
  font-size: clamp(48px, 8vw, 96px);
  line-height: 1;
  font-weight: 700;
  margin-bottom: 1rem;
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.05em;
}

.title-serif {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  color: var(--ivory);
  letter-spacing: -0.02em;
}

.title-sans {
  font-family: 'DM Sans', sans-serif;
  font-weight: 700;
  color: var(--gold);
  font-size: 0.55em;
  letter-spacing: -0.03em;
}

.hex-tagline {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: clamp(15px, 1.6vw, 19px);
  color: var(--ivory);
  opacity: 0.88;
  margin-bottom: 1.4rem;
}

.hex-formula {
  font-family: 'Fira Mono', monospace;
  font-size: 0.85rem;
  letter-spacing: 0.18em;
  color: var(--saffron);
  opacity: 0.85;
}

.opening-meta {
  position: absolute;
  bottom: 2.4rem;
  left: 50%;
  transform: translateX(-50%);
  font-family: 'Fira Mono', monospace;
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  color: var(--gold);
  opacity: 0.72;
  display: flex;
  gap: 1rem;
  z-index: 3;
}

.meta-dot { color: var(--saffron); }

@keyframes hexEnter {
  0%   { opacity: 0; transform: scale(0.9) translateY(20px); }
  60%  { opacity: 1; }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}

/* ---------- Honeycomb section ---------- */
.honeycomb {
  position: relative;
  padding: 8rem 6vw 6rem;
  background:
    radial-gradient(ellipse at 50% 0%, rgba(10,58,62,0.5), transparent 60%),
    var(--teal-deep);
  z-index: 2;
}

.honeycomb-heading {
  max-width: 720px;
  margin: 0 auto 5rem;
  text-align: center;
}

.honeycomb-heading h2 {
  font-size: clamp(28px, 4.5vw, 52px);
  line-height: 1.05;
  margin-bottom: 1.4rem;
  font-weight: 400;
}

.serif {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  color: var(--ivory);
}

.sans {
  font-family: 'DM Sans', sans-serif;
  font-weight: 700;
  color: var(--gold);
}

.honeycomb-heading p {
  font-size: clamp(15px, 1.4vw, 17px);
  color: var(--ivory);
  opacity: 0.78;
  max-width: 56ch;
  margin: 0 auto;
}

/* Honeycomb tessellation */
.hex-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.4rem 1.6rem;
  max-width: 1180px;
  margin: 0 auto;
  position: relative;
}

.hex-grid > .hex-cell:nth-child(2),
.hex-grid > .hex-cell:nth-child(5) {
  transform: translateY(2.6rem);
}

.hex-cell {
  position: relative;
  aspect-ratio: 1 / 1.05;
  cursor: pointer;
  transition: transform 0.6s cubic-bezier(.2,.7,.2,1), filter 0.6s ease;
}

.hex-shape {
  position: absolute;
  inset: 0;
  clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
  background: var(--bg, linear-gradient(135deg, var(--teal), var(--teal-deep))) center/cover no-repeat,
              linear-gradient(135deg, var(--teal), var(--teal-deep));
  filter: grayscale(100%) sepia(60%) hue-rotate(140deg) saturate(180%) brightness(0.65);
  transition: filter 0.6s ease;
}

.hex-shape::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(140deg, rgba(10,58,62,0.78) 0%, rgba(196,160,64,0.32) 100%);
  mix-blend-mode: multiply;
}

.hex-shape::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--glass);
  backdrop-filter: blur(8px) saturate(120%);
  -webkit-backdrop-filter: blur(8px) saturate(120%);
  border: 1px solid var(--glass-border);
  clip-path: inherit;
}

.hex-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 16% 14% 14%;
  z-index: 2;
  color: var(--ivory);
}

.hex-label {
  font-family: 'Fira Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.22em;
  color: var(--gold);
  margin-bottom: 0.6rem;
  text-transform: uppercase;
}

.hex-content h3 {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-weight: 400;
  font-size: clamp(17px, 2vw, 23px);
  line-height: 1.2;
  margin-bottom: 0.7rem;
  color: var(--ivory);
}

.hex-content p {
  font-size: 0.85rem;
  line-height: 1.55;
  opacity: 0.86;
  max-width: 90%;
}

.hex-meta {
  font-family: 'Fira Mono', monospace;
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  color: var(--saffron);
  margin-top: 0.8rem;
  opacity: 0.85;
}

.hex-cell:hover {
  transform: scale(1.05);
  z-index: 4;
}

.hex-cell:hover .hex-shape {
  filter: grayscale(60%) sepia(50%) hue-rotate(140deg) saturate(190%) brightness(0.85);
}

.hex-cell.is-focus {
  transform: scale(1.07);
  z-index: 5;
}

.hex-cell.is-focus .hex-shape {
  filter: grayscale(40%) sepia(40%) hue-rotate(140deg) saturate(200%) brightness(0.95);
}

/* ---------- Lattice section ---------- */
.lattice {
  position: relative;
  padding: 7rem 6vw;
  background:
    linear-gradient(180deg, var(--teal-deep), #0a3033 60%, var(--teal-deep));
  z-index: 2;
}

.lattice-inner {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 4rem;
  align-items: center;
}

.lattice-label {
  font-family: 'Fira Mono', monospace;
  font-size: 0.78rem;
  letter-spacing: 0.28em;
  color: var(--saffron);
  text-transform: uppercase;
  margin-bottom: 1.4rem;
}

.lattice-text h2 {
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.05;
  margin-bottom: 1.6rem;
  font-weight: 400;
}

.lattice-text p {
  margin-bottom: 1rem;
  color: var(--ivory);
  opacity: 0.82;
  max-width: 50ch;
}

.lattice-art {
  position: relative;
  aspect-ratio: 1 / 1;
  border-radius: 4px;
  overflow: hidden;
  background: var(--glass);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border: 1px solid var(--glass-border);
  padding: 1.5rem;
}

.lattice-art svg {
  width: 100%;
  height: 100%;
  display: block;
}

/* ---------- Duotone figure section ---------- */
.duotone-section {
  position: relative;
  padding: 6rem 6vw;
  background: var(--teal-deep);
  z-index: 2;
}

.duotone-figure {
  max-width: 1100px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 0.8fr;
  gap: 3rem;
  align-items: center;
}

.duotone-image {
  aspect-ratio: 4 / 3;
  background-image: url('https://images.unsplash.com/photo-1542273917363-3b1817f69a2d?auto=format&fit=crop&w=1400&q=70');
  background-size: cover;
  background-position: center;
  filter: grayscale(100%) sepia(80%) hue-rotate(140deg) saturate(220%) brightness(0.8);
  border-radius: 2px;
  position: relative;
}

.duotone-image::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(10,58,62,0.55), rgba(196,160,64,0.28));
  mix-blend-mode: multiply;
}

.duotone-figure figcaption {
  font-size: 0.95rem;
  color: var(--ivory);
  opacity: 0.86;
}

.cap-label {
  display: block;
  font-family: 'Fira Mono', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 0.9rem;
}

/* ---------- Footer ---------- */
.site-foot {
  position: relative;
  padding: 4rem 6vw 3rem;
  background: linear-gradient(180deg, var(--teal-deep), #050d0e);
  border-top: 1px solid rgba(196,160,64,0.18);
  z-index: 2;
}

.foot-row {
  max-width: 1100px;
  margin: 0 auto 2rem;
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: space-between;
  align-items: flex-end;
}

.foot-mark {
  font-family: 'Playfair Display', serif;
  font-style: italic;
  font-size: 2.2rem;
  color: var(--ivory);
}

.foot-mark span {
  font-family: 'DM Sans', sans-serif;
  font-style: normal;
  color: var(--gold);
  font-weight: 700;
}

.foot-meta {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  text-align: right;
  font-size: 0.85rem;
  color: var(--ivory);
  opacity: 0.7;
}

.foot-stamp {
  max-width: 1100px;
  margin: 0 auto;
  font-family: 'Fira Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.32em;
  color: var(--gold);
  opacity: 0.45;
  text-align: center;
  text-transform: lowercase;
}

/* ---------- Reveal animation for grid ---------- */
.hex-cell {
  opacity: 0;
  transform: translateY(30px) scale(0.95);
}

.hex-cell.is-revealed {
  opacity: 1;
  transform: translateY(0) scale(1);
  transition: opacity 0.8s ease, transform 0.8s cubic-bezier(.2,.7,.2,1);
}

.hex-cell.is-revealed:nth-child(2),
.hex-cell.is-revealed:nth-child(5) {
  transform: translateY(2.6rem) scale(1);
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hex-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .hex-grid > .hex-cell:nth-child(2),
  .hex-grid > .hex-cell:nth-child(5) {
    transform: translateY(1.6rem);
  }
  .hex-grid > .hex-cell.is-revealed:nth-child(2),
  .hex-grid > .hex-cell.is-revealed:nth-child(5) {
    transform: translateY(1.6rem) scale(1);
  }
  .lattice-inner,
  .duotone-figure {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .hex-grid {
    grid-template-columns: 1fr;
    gap: 1.4rem;
  }
  .hex-grid > .hex-cell:nth-child(2),
  .hex-grid > .hex-cell:nth-child(5) {
    transform: none;
  }
  .hex-grid > .hex-cell.is-revealed:nth-child(2),
  .hex-grid > .hex-cell.is-revealed:nth-child(5) {
    transform: scale(1);
  }
  .honeycomb { padding: 5rem 5vw 4rem; }
  .lattice, .duotone-section { padding: 4.5rem 5vw; }
  .foot-row { flex-direction: column; align-items: flex-start; }
  .foot-meta { text-align: left; }
}
