/* ============================================
   Connecting Domains - Static Site Styles
   ============================================ */

:root {
  --ed-bg: #0a0a0b;
  --ed-fg: #f4f4f3;
  --ed-muted: #8a8a8a;
  --ed-border: rgba(244, 244, 243, 0.12);
}

body.light-mode {
  --ed-bg: #f4f4f3;
  --ed-fg: #0a0a0b;
  --ed-muted: #6b6b6b;
  --ed-border: rgba(10, 10, 11, 0.12);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--ed-bg);
  color: var(--ed-fg);
  font-family: 'Inter Tight', -apple-system, BlinkMacSystemFont, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color 0.5s ease, color 0.5s ease;
}

::selection { background: var(--ed-fg); color: var(--ed-bg); }

a { color: inherit; text-decoration: none; }
button { background: none; border: none; color: inherit; font: inherit; cursor: pointer; padding: 0; }
ul { list-style: none; padding: 0; margin: 0; }

.mono { font-family: 'JetBrains Mono', monospace; }
.muted { color: var(--ed-muted); }
.fg { color: var(--ed-fg); }

.container {
  max-width: 1600px;
  margin: 0 auto;
  padding: 0 32px;
}

/* Display text */
.display {
  font-family: 'Inter Tight', sans-serif;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 0.88;
  text-transform: uppercase;
}

/* ---------- Grid background ---------- */
.grid-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
}
.grid-bg > span { border-right: 1px solid var(--ed-border); }
.grid-bg > span:last-child { border-right: none; }
@media (max-width: 768px) {
  .grid-bg { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- Cursor blob ---------- */
.cursor-blob {
  position: fixed;
  top: 0; left: 0;
  width: 14px; height: 14px;
  background: var(--ed-fg);
  border-radius: 999px;
  pointer-events: none;
  mix-blend-mode: difference;
  z-index: 9999;
  transform: translate(-100px, -100px);
  transition: width 0.25s ease, height 0.25s ease, opacity 0.3s ease;
}
.cursor-blob.hover { width: 64px; height: 64px; }
@media (max-width: 768px) { .cursor-blob { display: none; } }

/* ---------- Loader ---------- */
.loader {
  position: fixed; inset: 0;
  background: var(--ed-bg);
  display: flex; align-items: center; justify-content: center;
  z-index: 9998;
  transition: transform 1s cubic-bezier(0.76, 0, 0.24, 1);
}
.loader.gone { transform: translateY(-100%); }
.loader-text {
  font-size: 14px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ed-fg);
}
.loader-num {
  font-size: 18px;
  color: var(--ed-fg);
  position: absolute;
  bottom: 32px;
  right: 32px;
}

/* ---------- Header ---------- */
header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 24px 32px;
  transition: padding 0.5s ease, background 0.5s ease, border-color 0.5s ease;
  border-bottom: 1px solid transparent;
}
header.scrolled {
  padding: 14px 32px;
  background: color-mix(in srgb, var(--ed-bg) 70%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom-color: var(--ed-border);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
}
.logo-link { display: inline-flex; align-items: center; gap: 12px; color: var(--ed-fg); }
.logo-mark {
  display: inline-flex; align-items: center; justify-content: center;
  width: 36px; height: 36px; border-radius: 6px;
  background: var(--ed-fg); color: var(--ed-bg);
  transition: transform 0.5s ease;
}
.logo-link:hover .logo-mark { transform: rotate(90deg); }
.logo-text { font-size: 20px; font-weight: 500; letter-spacing: -0.01em; }

.nav-center { display: flex; align-items: center; gap: 40px; }
.nav-item {
  font-size: 13px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--ed-fg);
}

.nav-right { display: flex; align-items: center; gap: 16px; }
.theme-toggle { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ed-muted); }
.theme-toggle span.active { color: var(--ed-fg); }

@media (max-width: 900px) {
  .nav-center { display: none; }
  .theme-toggle { display: none; }
}

/* ---------- Button ---------- */
.ed-btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 22px;
  background: var(--ed-fg);
  color: var(--ed-bg);
  border: 1px solid var(--ed-fg);
  border-radius: 4px;
  font-weight: 500; font-size: 13px;
  letter-spacing: 0.08em; text-transform: uppercase;
  position: relative; overflow: hidden;
  transition: color 0.4s ease;
  cursor: pointer;
}
.ed-btn::before {
  content: '';
  position: absolute; inset: 0;
  background: var(--ed-bg);
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
  z-index: 0;
}
.ed-btn:hover::before { transform: translateY(0); }
.ed-btn:hover { color: var(--ed-fg); }
.ed-btn > * { position: relative; z-index: 1; }

.ed-btn.outline { background: transparent; color: var(--ed-fg); }
.ed-btn.outline::before { background: var(--ed-fg); }
.ed-btn.outline:hover { color: var(--ed-bg); }

/* ---------- Link underline ---------- */
.link-anim { position: relative; display: inline-block; }
.link-anim::after {
  content: '';
  position: absolute; left: 0; bottom: -2px;
  width: 100%; height: 1px;
  background: currentColor;
  transform-origin: right;
  transform: scaleX(0);
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.link-anim:hover::after { transform-origin: left; transform: scaleX(1); }

/* ---------- Reveal animation ---------- */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 1.2s cubic-bezier(0.22, 1, 0.36, 1), transform 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}
.reveal.in { opacity: 1; transform: translateY(0); }

/* ---------- Marquee ---------- */
@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.marquee-wrap { overflow: hidden; position: relative; }
.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee 40s linear infinite;
}
.marquee-track.fast { animation-duration: 25s; }
.marquee-track.slow { animation-duration: 60s; }
.marquee-track.reverse { animation-direction: reverse; }
.marquee-wrap:hover .marquee-track { animation-play-state: paused; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: 130px 32px 80px;
  overflow: hidden;
}
.hero-inner {
  position: relative; z-index: 10;
  max-width: 1600px; margin: 0 auto;
  width: 100%;
}
.hero-title {
  font-size: clamp(56px, 12.2vw, 220px);
  margin: 0;
}
.hero-title .line { display: block; overflow: hidden; }
.hero-title .line.right { text-align: right; }

/* Letter reveal */
.hero-title .line span,
.hero-title .line { will-change: transform; }
.hero-title .line {
  opacity: 0;
  transform: translateY(20%);
  transition: opacity 1s ease, transform 1.2s cubic-bezier(0.22, 1, 0.36, 1);
}
.hero-title.in .line { opacity: 1; transform: translateY(0); }
.hero-title.in .line:nth-child(1) { transition-delay: 0.1s; }
.hero-title.in .line:nth-child(2) { transition-delay: 0.35s; }

.hero-logo-wrap {
  display: flex; justify-content: center;
  margin: 48px 0;
}
.logo-3d {
  width: clamp(180px, 22vw, 360px);
  animation: float-y 6s ease-in-out infinite;
  transform-style: preserve-3d;
}
@keyframes float-y {
  0%, 100% { transform: translateY(0) rotateY(-8deg) rotateX(4deg); }
  50% { transform: translateY(-10px) rotateY(8deg) rotateX(-2deg); }
}

.hero-foot {
  display: flex; flex-direction: column; gap: 24px;
  margin-top: 32px;
}
@media (min-width: 768px) {
  .hero-foot { flex-direction: row; align-items: flex-end; justify-content: space-between; }
}
.hero-tag {
  max-width: 640px;
  color: var(--ed-muted);
  font-size: 18px;
  line-height: 1.6;
  margin: 0;
  transition-delay: 0.6s;
}

/* ---------- Services intro ---------- */
.services {
  position: relative;
  padding: 96px 0;
}
@media (min-width: 768px) {
  .services { padding: 128px 0; }
}
.grid-12 {
  display: grid; grid-template-columns: repeat(12, 1fr); gap: 40px;
}
@media (max-width: 768px) { .grid-12 { grid-template-columns: 1fr; gap: 30px; } }
.col-4 { grid-column: span 4; }
.col-8 { grid-column: span 8; }
@media (max-width: 768px) { .col-4, .col-8 { grid-column: span 1; } }
.eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  font-size: 12px; letter-spacing: 0.25em; text-transform: uppercase;
  color: var(--ed-muted);
}
.eb-line {
  display: inline-block; width: 28px; height: 1px;
  background: var(--ed-muted);
}
.big-copy {
  font-size: clamp(20px, 2.6vw, 36px);
  line-height: 1.25;
  letter-spacing: -0.01em;
  color: var(--ed-fg);
  margin: 0;
}

.brands-wrap {
  margin-top: 100px;
}
.brands-wrap .eyebrow { margin-bottom: 30px; }

.brand-item {
  display: inline-flex; align-items: center;
  padding: 32px 40px;
  font-size: clamp(28px, 4vw, 56px);
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--ed-fg);
  white-space: nowrap;
}
.brand-dot {
  display: inline-block;
  margin: 0 40px;
  opacity: 0.3;
}

/* ---------- Works ---------- */
.works {
  position: relative;
  padding: 96px 0;
  overflow: hidden;
}
@media (min-width: 768px) {
  .works { padding: 128px 0; }
}
.works-big {
  font-size: clamp(120px, 22vw, 360px);
  padding: 0 32px;
  color: var(--ed-fg);
  margin: 0;
  white-space: nowrap;
}
.works-inner { margin-top: 48px; }
@media (min-width: 768px) {
  .works-inner { margin-top: 80px; }
}
.works-grid {
  display: grid; grid-template-columns: 1fr; gap: 24px;
}
@media (min-width: 768px) {
  .works-grid { grid-template-columns: repeat(2, 1fr); gap: 40px; }
}

.work-card {
  position: relative; display: block;
  cursor: pointer;
}
.work-card.offset { margin-top: 0; }
@media (min-width: 768px) {
  .work-card.offset { margin-top: 96px; }
}
.work-img-wrap {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border-radius: 6px;
  background: #111;
}
.work-img-wrap img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 1.2s cubic-bezier(0.22, 1, 0.36, 1), filter 0.6s ease;
}
.work-card:hover .work-img-wrap img {
  transform: scale(1.06);
  filter: brightness(0.85);
}
.work-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 40%, rgba(0,0,0,0.7) 100%);
  opacity: 0;
  transition: opacity 0.5s ease;
}
.work-card:hover .work-overlay { opacity: 1; }
.work-meta {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 18px 20px;
  display: flex; justify-content: space-between; align-items: center;
  color: #fff;
  z-index: 2;
  transform: translateY(20%);
  opacity: 0;
  transition: transform 0.6s cubic-bezier(0.22, 1, 0.36, 1), opacity 0.4s ease;
  font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase;
}
.work-card:hover .work-meta { transform: translateY(0); opacity: 1; }
.work-title-row {
  display: flex; justify-content: space-between; align-items: flex-end;
  margin-top: 20px;
}
.work-title {
  font-size: clamp(18px, 1.8vw, 26px);
  font-weight: 500; letter-spacing: -0.01em;
  color: var(--ed-fg);
  margin: 0;
}
.work-num { font-size: 12px; opacity: 0.6; }

.works-cta {
  margin-top: 64px;
  display: flex; justify-content: center;
}

/* ---------- Awards ---------- */
.awards {
  padding: 96px 0;
}
@media (min-width: 768px) {
  .awards { padding: 128px 0; }
}
.awards-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin-bottom: 48px;
}
.awards-title { font-size: clamp(40px, 7vw, 120px); color: var(--ed-fg); margin: 0; }
.small-muted { font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--ed-muted); }
.awards-list { border-top: 1px solid var(--ed-border); }

.award-row {
  display: grid;
  grid-template-columns: 60px 1fr auto 80px;
  align-items: center;
  gap: 24px;
  padding: 28px 0;
  border-bottom: 1px solid var(--ed-border);
  transition: padding-left 0.5s cubic-bezier(0.22, 1, 0.36, 1);
  cursor: pointer;
}
@media (max-width: 768px) {
  .award-row { grid-template-columns: 40px 1fr 50px; }
  .award-row .award-year { display: none; }
}
.award-row:hover { padding-left: 20px; }
.award-num { font-family: 'JetBrains Mono', monospace; font-size: 12px; opacity: 0.6; }
.award-name { font-size: clamp(20px, 2.6vw, 30px); font-weight: 500; letter-spacing: -0.01em; color: var(--ed-fg); margin: 0; }
.award-sub { font-size: 14px; color: var(--ed-muted); margin: 4px 0 0; }
.award-year { font-family: 'JetBrains Mono', monospace; font-size: 12px; opacity: 0.6; }
.award-arrow {
  display: inline-flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid var(--ed-border);
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1);
}
.award-row:hover .award-arrow { transform: translateX(8px); }

/* ---------- About ---------- */
.about {
  padding: 96px 0;
}
@media (min-width: 768px) {
  .about { padding: 144px 0; }
}
.about-title {
  font-size: clamp(30px, 5vw, 64px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.1;
  max-width: 1300px;
  color: var(--ed-fg);
  margin: 0;
}
.about-grid {
  margin-top: 64px;
  display: grid; grid-template-columns: 1fr; gap: 40px;
  align-items: start;
}
@media (min-width: 768px) {
  .about-grid { grid-template-columns: 7fr 5fr; gap: 64px; }
}
.about-copy p {
  font-size: clamp(16px, 1.4vw, 20px);
  line-height: 1.55;
  color: var(--ed-muted);
  margin: 0;
}
.about-copy .ed-btn { margin-top: 40px; }
.about-logo-wrap {
  display: flex; justify-content: center;
}
@media (min-width: 768px) {
  .about-logo-wrap { justify-content: flex-end; }
}
.about-logo { width: clamp(220px, 28vw, 420px); }

/* ---------- Service tags ---------- */
.service-tags {
  padding: 96px 0;
  border-top: 1px solid var(--ed-border);
  border-bottom: 1px solid var(--ed-border);
}
@media (min-width: 768px) {
  .service-tags { padding: 128px 0; }
}
.big-marquee { margin-bottom: 64px; }
@media (min-width: 768px) {
  .big-marquee { margin-bottom: 96px; }
}
.memo-text {
  font-size: clamp(48px, 9vw, 160px);
  padding: 0 32px;
  white-space: nowrap;
  color: var(--ed-fg);
  margin: 0;
}
.tags-grid {
  display: grid; grid-template-columns: 1fr; gap: 64px;
}
@media (min-width: 768px) {
  .tags-grid { grid-template-columns: 1fr 1fr; }
}
.tags-grid .eyebrow { margin-bottom: 30px; }
.chips { display: flex; flex-wrap: wrap; gap: 12px; }
.tag-chip {
  display: inline-flex; align-items: center;
  padding: 10px 18px;
  border: 1px solid var(--ed-border);
  border-radius: 999px;
  font-size: 14px; font-weight: 400;
  white-space: nowrap;
  color: var(--ed-fg);
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
  cursor: pointer;
}
.tag-chip:hover {
  background: var(--ed-fg);
  color: var(--ed-bg);
  border-color: var(--ed-fg);
}

/* ---------- Testimonials ---------- */
.testimonials {
  padding: 96px 0;
  overflow: hidden;
}
@media (min-width: 768px) {
  .testimonials { padding: 128px 0; }
}
.testimonials .container { margin-bottom: 48px; }
.test-title {
  margin-top: 24px;
  font-size: clamp(28px, 4vw, 56px);
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1.15;
  max-width: 1100px;
  color: var(--ed-fg);
}
.test-card {
  flex-shrink: 0;
  width: 380px;
  margin-right: 20px;
  padding: 28px;
  border: 1px solid var(--ed-border);
  border-radius: 8px;
  background: rgba(255,255,255,0.02);
}
@media (max-width: 768px) { .test-card { width: 280px; } }
.test-head { display: flex; align-items: center; gap: 12px; margin-bottom: 20px; }
.test-initials {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--ed-fg); color: var(--ed-bg);
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px; font-weight: 600;
}
.test-stars { display: inline-flex; gap: 4px; color: var(--ed-fg); }
.test-quote { font-size: 16px; line-height: 1.6; color: var(--ed-fg); margin: 0 0 20px; }
.test-name {
  font-family: 'JetBrains Mono', monospace;
  font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ed-muted);
}

/* ---------- Footer ---------- */
.footer {
  background: #000;
  color: #f4f4f3;
  padding: 96px 32px 40px;
  border-top: 1px solid rgba(255,255,255,0.08);
}
.footer-cta { text-align: center; }
.eyebrow-center { font-size: 12px; letter-spacing: 0.3em; text-transform: uppercase; opacity: 0.6; }
.footer-h {
  margin-top: 24px;
  font-size: clamp(32px, 5vw, 80px);
  font-weight: 500;
  letter-spacing: -0.02em;
}
.mt-8 { margin-top: 32px; }
.mt-10 { margin-top: 40px; }

.brand-big {
  margin-top: 80px;
  overflow: hidden;
}
@media (min-width: 768px) { .brand-big { margin-top: 112px; } }
.brand-big-text {
  text-align: center;
  font-size: clamp(40px, 9.4vw, 140px);
  line-height: 0.92;
  white-space: nowrap;
  margin: 0;
}

.footer-cols {
  margin-top: 64px;
  padding-top: 40px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 40px;
}
@media (min-width: 768px) {
  .footer-cols { grid-template-columns: repeat(4, 1fr); }
}
.fc-title { font-size: 14px; letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.6; margin: 0 0 20px; }
.fc-col ul li { margin-bottom: 12px; font-size: 16px; }

.footer-bottom {
  margin-top: 64px;
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.08);
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
  opacity: 0.6;
}
@media (min-width: 768px) {
  .footer-bottom { flex-direction: row; align-items: center; justify-content: space-between; }
}

/* ---------- Status bar ---------- */
.status-bar {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 40;
  padding: 20px 32px;
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12px; letter-spacing: 0.2em; text-transform: uppercase;
  color: var(--ed-fg);
  pointer-events: none;
}
.sound-btn, .status-right { pointer-events: auto; }
.sound-btn {
  display: inline-flex; align-items: center; gap: 8px;
  opacity: 0.8;
  transition: opacity 0.3s ease;
}
.sound-btn:hover { opacity: 1; }
.status-right { display: flex; align-items: center; gap: 24px; opacity: 0.8; }
@media (max-width: 768px) {
  .status-right { display: none; }
}
.lang button { font: inherit; padding: 0 4px; transition: opacity 0.3s ease; }
.lang button.dim { opacity: 0.5; }
.lang button:hover { opacity: 1; }

.sound-bars { display: inline-flex; gap: 2px; align-items: end; height: 12px; }
.sound-bars span {
  width: 2px;
  background: currentColor;
  border-radius: 1px;
  animation: bar 1.2s ease-in-out infinite;
}
.sound-bars span:nth-child(1) { animation-delay: -0.4s; height: 60%; }
.sound-bars span:nth-child(2) { animation-delay: -0.2s; height: 100%; }
.sound-bars span:nth-child(3) { animation-delay: 0s; height: 40%; }
.sound-bars span:nth-child(4) { animation-delay: -0.3s; height: 80%; }
@keyframes bar {
  0%, 100% { transform: scaleY(0.4); }
  50% { transform: scaleY(1); }
}
