/* Kaiserwerk Ltd */

:root {
  --bg:     #080808;
  --bg2:    #0f0f0f;
  --fg:     #f0ece4;
  --fg2:    #8a8278;
  --fg3:    #504840;
  --border: #222018;
  --accent: #4f86c6;   /* steel blue */
  --nav-bg: rgba(8,8,8,0.95);
}

[data-theme="light"] {
  --bg:     #ffffff;
  --bg2:    #f5f5f5;
  --fg:     #0a0a0a;
  --fg2:    #555555;
  --fg3:    #999999;
  --border: #e0e0e0;
  --accent: #4f86c6;   /* same steel blue in both modes */
  --nav-bg: rgba(255,255,255,0.96);
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  font-family: 'Courier Prime', 'Courier New', monospace;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.7;
  overflow-x: hidden;
  transition: background .4s, color .4s;
}

a { color: inherit; text-decoration: none; }
img, video { display: block; }

.container {
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 48px;
}
@media (max-width: 768px) { .container { padding: 0 24px; } }

/* ── NAV ── */
#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  padding: 0 48px;
  height: 64px;
  transition: background .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
#nav.scrolled {
  background: var(--nav-bg);
  backdrop-filter: blur(12px);
  border-color: var(--border);
}
@media (max-width: 768px) { #nav { padding: 0 24px; } }

.logo {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: .5px;
  color: var(--accent);
  margin-right: auto;
}

#nav ul {
  display: flex;
  list-style: none;
  gap: 36px;
  margin-right: 32px;
}
#nav ul a {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: .3px;
  color: var(--fg2);
  transition: color .2s;
}
#nav ul a:hover { color: var(--fg); }

.nav-right { display: flex; align-items: center; gap: 12px; }

#theme-toggle {
  background: none;
  border: 1px solid var(--border);
  width: 36px; height: 36px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  color: var(--fg2);
  transition: border-color .2s, color .2s;
}
#theme-toggle:hover { border-color: var(--fg); color: var(--fg); }
[data-theme="dark"] .sun { display: none; }
[data-theme="light"] .moon { display: none; }

#menu-btn {
  display: none;
  flex-direction: column;
  gap: 6px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
#menu-btn span {
  display: block;
  width: 22px; height: 1.5px;
  background: var(--fg);
  transition: all .25s;
}
#menu-btn.open span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
#menu-btn.open span:nth-child(2) { transform: translateY(-7.5px) rotate(-45deg); }

#mobile-nav {
  position: fixed;
  top: 64px; left: 0; right: 0;
  z-index: 199;
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
  flex-direction: column;
  padding: 0;
  max-height: 0;
  overflow: hidden;
  transition: max-height .35s ease, padding .35s ease;
  display: flex;
}
#mobile-nav.open {
  max-height: 280px;
  padding: 8px 0 16px;
}
#mobile-nav a {
  font-family: 'Courier Prime', monospace;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--fg2);
  padding: 14px 24px;
  border-bottom: 1px solid var(--border);
  transition: color .2s, background .2s;
}
#mobile-nav a:last-child { border-bottom: none; }
#mobile-nav a:hover { color: var(--fg); background: var(--bg); }

@media (max-width: 768px) {
  #nav ul { display: none; }
  #menu-btn { display: flex; }
}

/* ── HERO ── */
#hero {
  position: relative;
  height: 100vh;
  min-height: 640px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
}

#video-wrap {
  position: absolute;
  inset: 0;
}
#video-wrap video {
  width: 100%; height: 100%;
  object-fit: cover;
  opacity: .92;
  filter: grayscale(10%);
}
#video-overlay {
  position: absolute;
  inset: 0;
  /* Always dark — hero is never affected by light mode */
  background: linear-gradient(to top, rgba(4,4,4,0.72) 0%, rgba(4,4,4,0.15) 55%, transparent 100%);
}

#hero-text {
  position: relative;
  z-index: 2;
  padding: 0 48px;
  max-width: 820px;
  display: flex;
  flex-direction: column;
  align-items: center;
}
@media (max-width: 768px) { #hero-text { padding: 0 24px; } }

.eyebrow {
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(240,236,228,0.5);
  margin-bottom: 24px;
  opacity: 0;
  animation: fadeUp .8s ease forwards .2s;
  text-align: center;
}

#hero-text h1 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4.5vw, 68px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -.5px;
  margin-bottom: 24px;
  color: #f0ece4;
  opacity: 0;
  animation: fadeUp .9s ease forwards .4s;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25em 0.6em;
  justify-content: center;
  align-items: baseline;
}
#hero-text h1 span {
  white-space: nowrap;
}

.hero-desc {
  font-size: 16px;
  color: rgba(240,236,228,0.55);
  line-height: 1.7;
  margin-bottom: 40px;
  opacity: 0;
  animation: fadeUp .8s ease forwards .7s;
}

.cta {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .3px;
  border: 1px solid var(--accent);
  padding: 12px 28px;
  color: var(--accent);
  border-radius: 2px;
  transition: border-color .25s, color .25s, background .25s;
  opacity: 0;
  animation: fadeUp .8s ease forwards 1s;
}
.cta span { font-size: 18px; transition: transform .25s; }
.cta:hover { border-color: #f0ece4; color: #f0ece4; background: transparent; }
.cta:hover span { transform: translateY(4px); }

#hero-scroll {
  position: absolute;
  bottom: 40px; right: 48px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  opacity: 0;
  animation: fadeUp .8s ease forwards 1.4s;
  z-index: 2;
}
#hero-scroll span {
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--fg3);
  writing-mode: vertical-rl;
}
.scroll-line {
  width: 1px; height: 48px;
  background: linear-gradient(to bottom, var(--fg3), transparent);
  animation: scrollPulse 2.5s ease-in-out infinite;
}
@keyframes scrollPulse {
  0%,100% { opacity: 0; transform: scaleY(0); transform-origin: top; }
  50%      { opacity: 1; transform: scaleY(1); }
}

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

/* ── FLOATING SIDE ── */
#float-side {
  position: fixed;
  left: 28px;
  top: 50%;
  transform: translateY(-50%);
  z-index: 50;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  pointer-events: none;
  transition: opacity .4s;
}
#float-side.hidden { opacity: 0; }
.fs-loc {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--fg3);
  writing-mode: vertical-rl;
}
.fs-line {
  width: 1px;
  height: 48px;
  background: var(--border);
}
.fs-label {
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--fg3);
  writing-mode: vertical-rl;
}
@media (max-width: 1100px) { #float-side { display: none; } }


/* ── SECTIONS ── */
.section {
  padding: 120px 0;
}
.dark-section {
  background: var(--bg2);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 20px;
}

h2.section-title,
h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4vw, 52px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.3px;
  margin-bottom: 64px;
}
h2 em { font-style: italic; color: var(--fg2); }

/* ── ABOUT ── */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
@media (max-width: 768px) { .about-grid { grid-template-columns: 1fr; gap: 40px; } }

.about-left h2 { margin-bottom: 0; }

.about-right p {
  font-size: 16px;
  color: var(--fg2);
  line-height: 1.8;
  margin-bottom: 20px;
}
.about-right p:last-of-type { margin-bottom: 48px; }

.stats-row {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 24px;
  border-top: 1px solid var(--border);
  padding-top: 32px;
}
@media (max-width: 600px) { .stats-row { grid-template-columns: 1fr; } }

.stat strong {
  display: block;
  font-family: 'Playfair Display', serif;
  font-size: 32px;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 6px;
}
.stat span {
  font-size: 12px;
  color: var(--fg3);
  line-height: 1.4;
}

/* ── VENTURES ── */
.venture-cards {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 2px;
  background: var(--border);
}
@media (max-width: 900px) { .venture-cards { grid-template-columns: 1fr; } }

.vcard {
  background: var(--bg2);
  padding: 40px 36px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: background .25s;
}
.vcard:hover { background: var(--bg); }
.vcard.featured { background: var(--fg); color: var(--bg); }
.vcard.featured:hover { background: #e8e8e8; }
[data-theme="light"] .vcard.featured { background: var(--fg); color: var(--bg); }

.vcard-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.vnum {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--fg3);
}
.vcard.featured .vnum { color: rgba(0,0,0,0.35); }
.vtag {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--fg3);
}
.vcard.featured .vtag { color: rgba(0,0,0,0.45); }

.vcard h3 {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
}
.vcard p {
  font-size: 14px;
  line-height: 1.75;
  color: var(--fg2);
  flex: 1;
}
.vcard.featured p { color: rgba(0,0,0,0.6); }

.vcard-footer {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.vcard.featured .vcard-footer { border-color: rgba(0,0,0,0.12); }
.vcard-footer span {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--fg3);
}
.vcard.featured .vcard-footer span { color: rgba(0,0,0,0.45); }

/* ── VENTURE DEEP-DIVES ── */
.venture-deep {
  position: relative;
  min-height: 100vh;
  width: 100%;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
@media (max-width: 768px) {
  .venture-deep {
    min-height: 100svh;
    height: auto;
    padding-top: 100px;
    padding-bottom: 60px;
    align-items: flex-start;
  }
  .vd-content {
    padding-top: 0;
    padding-bottom: 40px;
    justify-content: flex-start;
  }
  .vd-inner {
    padding-top: 0;
  }
}

.vd-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}
.vd-bg img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 30%;
  filter: grayscale(70%) contrast(1.1);
  transform: scale(1.08);
  transition: transform 8s ease;
}
.venture-deep:hover .vd-bg img {
  transform: scale(1.0);
}

.vd-veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(8,8,8,0.88) 0%,
    rgba(8,8,8,0.45) 45%,
    rgba(8,8,8,0.10) 100%
  );
}
.vd-veil-dark {
  background: linear-gradient(
    to top,
    rgba(4,4,4,0.90) 0%,
    rgba(4,4,4,0.50) 45%,
    rgba(4,4,4,0.12) 100%
  );
}
.vd-veil-light {
  background: linear-gradient(
    to top,
    rgba(8,8,8,0.88) 0%,
    rgba(8,8,8,0.45) 45%,
    rgba(8,8,8,0.08) 100%
  );
}

/* Abstract background for Dinar */
.vd-abstract {
  width: 100%; height: 100%;
  background:
    repeating-linear-gradient(
      0deg,
      transparent,
      transparent 40px,
      rgba(216,208,192,0.03) 40px,
      rgba(216,208,192,0.03) 41px
    ),
    repeating-linear-gradient(
      90deg,
      transparent,
      transparent 40px,
      rgba(216,208,192,0.03) 40px,
      rgba(216,208,192,0.03) 41px
    ),
    var(--bg2);
}

.vd-content {
  position: relative;
  z-index: 2;
  width: 100%;
  height: 100%;
  padding-top: 100px;
  padding-bottom: 48px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

/* Top row: number + title left, body text right */
.vd-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: end;
  flex: 1;
  padding-top: 40px;
}
@media (max-width: 860px) {
  .vd-inner { grid-template-columns: 1fr; gap: 24px; }
}

/* Left col: number + heading */
.vd-left {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.vd-num {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--accent);
  opacity: 0.7;
  display: block;
  margin-bottom: 20px;
}

.vd-left h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(40px, 6vw, 88px);
  font-weight: 700;
  line-height: 0.95;
  color: #f0ece4;
  margin-bottom: 0;
  letter-spacing: -1px;
}

/* Right col: label + body + attrs */
.vd-right {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding-bottom: 4px;
}

.vd-right .label {
  color: var(--accent);
  opacity: 0.85;
  margin-bottom: 0;
}

.vd-right p {
  font-size: clamp(13px, 1.4vw, 16px);
  line-height: 1.9;
  color: rgba(216,208,192,0.6);
  margin-bottom: 0;
}

.vd-attrs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px 32px;
  border-top: 1px solid rgba(216,208,192,0.12);
  padding-top: 28px;
  max-width: 560px;
}
@media (max-width: 600px) { .vd-attrs { grid-template-columns: 1fr; } }

.vd-attrs div { display: flex; flex-direction: column; gap: 4px; }
.vd-attrs span {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: rgba(216,208,192,0.35);
}
.vd-attrs strong {
  font-family: 'Courier Prime', monospace;
  font-size: 14px;
  font-weight: 700;
  color: var(--accent);
}

/* Footnote */
.vd-footnote {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  border-top: 1px solid rgba(216,208,192,0.1);
  padding-top: 20px;
  max-width: 700px;
}
.fn-mark {
  font-family: 'Playfair Display', serif;
  font-size: 18px;
  color: var(--accent);
  line-height: 1;
  flex-shrink: 0;
  margin-top: 2px;
}
.vd-footnote p {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 11px;
  line-height: 1.75;
  color: rgba(216,208,192,0.3);
  font-style: normal;
}
.vd-footnote p em {
  font-style: italic;
  color: rgba(216,208,192,0.45);
}

/* ── VENTURE LIST ── */
.venture-list {
  display: flex;
  flex-direction: column;
}
.vrow {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 48px;
  padding: 48px 0;
  border-bottom: 1px solid var(--border);
  transition: background .2s;
}
.vrow:first-child { border-top: 1px solid var(--border); }
.vrow:hover { background: var(--bg2); padding-left: 16px; padding-right: 16px; margin: 0 -16px; }
@media (max-width: 768px) { .vrow { grid-template-columns: 1fr; gap: 16px; } }

.vrow-left {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 4px;
}
.vrow-n {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--accent);
}
.vrow-tag {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--fg3);
}
.vrow-right h3 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(20px, 2.5vw, 28px);
  font-weight: 700;
  margin-bottom: 14px;
  line-height: 1.2;
  color: var(--fg);
}
.vrow-right p {
  font-size: 15px;
  line-height: 1.8;
  color: var(--fg2);
  margin-bottom: 20px;
}
.vrow-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.vrow-tags span {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 1px;
  text-transform: uppercase;
  border: 1px solid var(--border);
  padding: 4px 12px;
  color: var(--fg3);
  border-radius: 2px;
}

/* ── EFUELS ── */
.process-steps {
  display: grid;
  grid-template-columns: 1fr 24px 1fr 24px 1fr 24px 1fr;
  gap: 0;
  align-items: start;
  margin-bottom: 72px;
  border: 1px solid var(--border);
}
@media (max-width: 860px) {
  .process-steps { grid-template-columns: 1fr; }
  .step-arrow { text-align: center; padding: 8px 0; transform: rotate(90deg); }
}

.step {
  padding: 36px 28px;
  border-right: 1px solid var(--border);
}
.step:last-child { border-right: none; }
.step-n {
  display: block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  color: var(--fg3);
  margin-bottom: 12px;
}
.step h4 {
  font-family: 'Playfair Display', serif;
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 8px;
}
.step p {
  font-size: 13px;
  line-height: 1.7;
  color: var(--fg2);
}
.step-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--fg3);
  font-size: 18px;
  align-self: center;
}

.phase-cards {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
@media (max-width: 640px) { .phase-cards { grid-template-columns: 1fr; } }

.phase-card {
  border: 1px solid var(--border);
  border-top: 2px solid var(--accent);
  padding: 40px;
  border-radius: 2px;
}
.phase-label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 28px;
}
.phase-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 24px;
  margin-bottom: 24px;
}
.phase-stats div { display: flex; flex-direction: column; gap: 3px; }
.phase-stats span {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--fg3);
}
.phase-stats strong {
  font-size: 16px;
  font-weight: 600;
  color: var(--accent);
}
.phase-note {
  font-size: 13px;
  color: var(--fg3);
  line-height: 1.6;
  border-top: 1px solid var(--border);
  padding-top: 16px;
  font-style: italic;
}

/* ── QUOTE ── */
#quote-section {
  text-align: center;
}
#quote-section blockquote {
  font-family: 'Playfair Display', serif;
  font-size: clamp(22px, 3.5vw, 40px);
  font-weight: 400;
  font-style: italic;
  line-height: 1.5;
  color: var(--fg);
  max-width: 800px;
  margin: 0 auto 20px;
}
#quote-section cite {
  font-size: 12px;
  letter-spacing: 1px;
  color: var(--fg3);
}

/* ── CONTACT ── */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
@media (max-width: 768px) { .contact-grid { grid-template-columns: 1fr; gap: 48px; } }

#contact h2 { margin-bottom: 16px; }
#contact p {
  font-size: 15px;
  color: var(--fg2);
  line-height: 1.75;
}

.contact-details { padding-top: 8px; }
.cd-row {
  display: flex;
  gap: 24px;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  align-items: baseline;
}
.cd-row:last-child { border-bottom: none; }
.cd-row span {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--fg3);
  min-width: 120px;
}
.cd-row strong {
  font-size: 14px;
  font-weight: 500;
  color: var(--accent);
}

/* ── FOOTER ── */
footer {
  padding: 36px 0;
  border-top: 1px solid var(--border);
  background: var(--bg2);
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}
.footer-logo {
  font-family: 'Playfair Display', serif;
  font-size: 16px;
  font-weight: 700;
  color: var(--accent);
}
.footer-copy {
  font-size: 12px;
  color: var(--fg3);
}

/* ── REVEAL ANIMATION ── */
.reveal {
  opacity: 0;
  transform: translateY(32px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }
