:root {
  --ink: #f7f5ef;
  --muted: #b8c1c4;
  --paper: #f3efe5;
  --charcoal: #0a0c0d;
  --line: rgba(255, 255, 255, 0.16);
  --accent: #d6b36a;
  --sea: #163f4a;
  --brick: #8d3026;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--charcoal);
  color: var(--ink);
  font-family: "Inter", "Pretendard", "Noto Sans KR", "Apple SD Gothic Neo", Arial, sans-serif;
  line-height: 1.55;
}

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

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  min-height: 76px;
  padding: 20px clamp(18px, 4vw, 56px);
  background: linear-gradient(180deg, rgba(6, 8, 9, 0.84), rgba(6, 8, 9, 0));
}

.brand {
  flex: 0 0 auto;
}

.brand img {
  width: auto;
  height: 62px;
  filter: brightness(0) invert(1);
}

nav {
  display: flex;
  align-items: center;
  gap: clamp(14px, 2.4vw, 34px);
  margin-left: auto;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0;
  text-transform: uppercase;
}

nav a {
  color: rgba(255, 255, 255, 0.78);
}

nav a:hover {
  color: #fff;
}

.language-switch {
  display: inline-flex;
  flex: 0 0 auto;
  gap: 2px;
  margin-left: clamp(14px, 2.2vw, 28px);
  padding: 3px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 4px;
  background: rgba(0, 0, 0, 0.24);
  backdrop-filter: blur(8px);
}

.language-switch button {
  min-width: 38px;
  min-height: 30px;
  border: 0;
  border-radius: 2px;
  background: transparent;
  color: rgba(255, 255, 255, 0.68);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 900;
}

.language-switch button.is-active {
  background: var(--ink);
  color: #101112;
}

.hero {
  position: relative;
  min-height: 72vh;
  overflow: hidden;
  background: #000;
  isolation: isolate;
}

.hero-video,
.hero-fallback,
.hero-shade {
  position: absolute;
  inset: 0;
}

.hero-video,
.hero-fallback {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-fallback {
  background:
    linear-gradient(90deg, rgba(0, 0, 0, 0.68), rgba(0, 0, 0, 0.08)),
    url("assets/work-02.jpg") center / cover;
  z-index: 0;
}

.hero-video {
  z-index: 1;
}

.hero-shade {
  z-index: 2;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.2), rgba(0, 0, 0, 0.18));
}

.intro-flash {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  gap: 16px;
  padding: 28px;
  text-align: center;
  pointer-events: none;
}

.intro-flash img {
  width: min(360px, 70vw);
  filter: brightness(0) invert(1) drop-shadow(0 0 28px rgba(255, 255, 255, 0.2));
  opacity: 0;
  animation: logoFlash 3.6s ease-in-out infinite;
}

.intro-flash span {
  color: rgba(255, 255, 255, 0.66);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
  opacity: 0;
  animation: textFlash 3.6s ease-in-out infinite;
}

.intro-flash i {
  position: absolute;
  width: 42vw;
  max-width: 560px;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.86), transparent);
  opacity: 0;
  animation: scanFlash 3.6s ease-in-out infinite;
}

.hero:not(.video-unavailable) .intro-flash {
  opacity: 0.78;
}

.hero.video-ready .intro-flash {
  opacity: 0;
  transition: opacity 0.6s ease;
}

.hero.video-unavailable .hero-video {
  display: none;
}

.hero.video-unavailable .hero-fallback {
  background:
    radial-gradient(circle at 50% 44%, rgba(255, 255, 255, 0.12), rgba(0, 0, 0, 0) 34%),
    #000;
}

@keyframes logoFlash {
  0%,
  100% {
    opacity: 0.34;
    transform: scale(0.98);
  }
  18%,
  46% {
    opacity: 1;
    transform: scale(1);
  }
  52% {
    opacity: 0.2;
  }
  58% {
    opacity: 0.95;
  }
}

@keyframes textFlash {
  0%,
  14%,
  100% {
    opacity: 0;
  }
  24%,
  62% {
    opacity: 1;
  }
}

@keyframes scanFlash {
  0%,
  22%,
  100% {
    opacity: 0;
    transform: translateY(80px) scaleX(0.2);
  }
  34% {
    opacity: 0.84;
    transform: translateY(0) scaleX(1);
  }
  48% {
    opacity: 0;
    transform: translateY(-80px) scaleX(0.44);
  }
}

.hero-statement {
  padding: clamp(52px, 7vw, 92px) clamp(20px, 6vw, 84px) clamp(48px, 6vw, 78px);
  background:
    linear-gradient(180deg, #060707, #0a0c0d 62%, #111416);
  border-bottom: 1px solid var(--line);
}

.hero-content {
  position: relative;
  width: min(980px, 100%);
}

.kicker,
.eyebrow {
  margin: 0 0 14px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 22px;
  font-size: clamp(40px, 6.6vw, 92px);
  line-height: 0.94;
  letter-spacing: 0;
  font-weight: 760;
}

.hero-copy {
  width: min(680px, 100%);
  margin-bottom: 30px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(17px, 2.1vw, 24px);
  word-break: keep-all;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid rgba(255, 255, 255, 0.48);
  border-radius: 4px;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.button.primary {
  background: var(--ink);
  border-color: var(--ink);
  color: #101112;
}

.button.ghost {
  background: rgba(255, 255, 255, 0.04);
}

.button.is-disabled {
  opacity: 0.52;
  pointer-events: none;
}

.intro-band {
  display: grid;
  gap: 8px;
  padding: 30px clamp(20px, 6vw, 84px);
  background: var(--paper);
  color: #141515;
}

.intro-band p {
  margin: 0;
  font-size: clamp(26px, 4vw, 58px);
  line-height: 1;
  font-weight: 900;
}

.intro-band span {
  color: #52504b;
  font-size: 15px;
  font-weight: 700;
}

.section {
  width: min(1180px, calc(100% - 40px));
  margin: 0 auto;
  padding: clamp(72px, 9vw, 128px) 0;
}

.section-heading {
  display: grid;
  gap: 8px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(34px, 5vw, 66px);
  line-height: 1.02;
  letter-spacing: 0;
  word-break: keep-all;
}

.about-section {
  display: grid;
  grid-template-columns: minmax(240px, 0.82fr) minmax(260px, 0.7fr) minmax(320px, 1fr);
  gap: clamp(28px, 4.5vw, 68px);
  align-items: start;
}

.about-visual {
  position: relative;
  min-height: 420px;
  overflow: hidden;
  background: #111;
}

.about-visual img {
  width: 100%;
  height: 100%;
  min-height: 420px;
  object-fit: cover;
}

.about-visual::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(0, 0, 0, 0.02), rgba(0, 0, 0, 0.72));
}

.about-visual-caption {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 2;
  display: grid;
  gap: 4px;
}

.about-visual-caption strong {
  font-size: 20px;
  line-height: 1;
}

.about-visual-caption span {
  color: rgba(255, 255, 255, 0.74);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.about-copy {
  color: rgba(255, 255, 255, 0.76);
  font-size: 18px;
  word-break: keep-all;
}

.stats {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.stats div {
  padding: 28px 24px;
  border-right: 1px solid var(--line);
}

.stats div:last-child {
  border-right: 0;
}

.stats strong {
  display: block;
  font-size: clamp(46px, 7vw, 86px);
  line-height: 1;
}

.stats span {
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.service-section {
  border-top: 1px solid var(--line);
}

.service-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  margin-top: 42px;
  background: rgba(255, 255, 255, 0.18);
}

.service-grid article {
  min-height: 320px;
  padding: 26px;
  background: #121719;
}

.service-grid h3,
.contact-grid h3 {
  margin-bottom: 12px;
  font-size: 20px;
}

.service-grid p {
  color: rgba(255, 255, 255, 0.72);
  word-break: keep-all;
}

.work-section {
  background: var(--paper);
  color: #111313;
}

.work-heading {
  padding-bottom: 42px;
}

.work-gallery {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  padding: 0 clamp(8px, 2vw, 24px) clamp(8px, 2vw, 24px);
}

figure {
  position: relative;
  min-height: 330px;
  margin: 0;
  overflow: hidden;
  background: #111;
}

figure.wide {
  grid-column: span 2;
}

figure img {
  width: 100%;
  height: 100%;
  min-height: 330px;
  object-fit: cover;
  transition: transform 0.7s ease, filter 0.7s ease;
}

figure::after {
  position: absolute;
  inset: 0;
  content: "";
  background: linear-gradient(180deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.56));
}

figure:hover img {
  transform: scale(1.04);
  filter: saturate(1.08);
}

figcaption {
  position: absolute;
  left: 18px;
  bottom: 16px;
  z-index: 2;
  color: #fff;
  padding: 8px 10px;
  background: rgba(0, 0, 0, 0.42);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 3px;
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
}

.showreel-section {
  display: grid;
  grid-template-columns: 0.64fr 1fr;
  gap: clamp(28px, 5vw, 72px);
  align-items: start;
}

.video-frame {
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background: #000;
}

.video-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
}

.contact-section {
  background:
    linear-gradient(90deg, rgba(10, 12, 13, 0.82), rgba(10, 12, 13, 0.56)),
    url("assets/work-04.jpg") center / cover fixed;
}

.contact-inner {
  padding-bottom: 70px;
}

.contact-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 40px;
}

.contact-grid article {
  min-height: 230px;
  padding: 24px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.34);
  backdrop-filter: blur(10px);
}

.contact-grid p {
  margin-bottom: 16px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.contact-grid a,
.contact-grid span {
  display: block;
  margin-top: 8px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
  overflow-wrap: anywhere;
}

.address-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  margin-top: 28px;
  color: rgba(255, 255, 255, 0.78);
}

.contact-form {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 34px;
  padding: 22px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(0, 0, 0, 0.36);
}

.contact-form label,
.admin-panel label {
  display: grid;
  gap: 8px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.contact-form .full {
  grid-column: 1 / -1;
}

.contact-form input,
.contact-form textarea,
.admin-panel input,
.admin-panel textarea {
  width: 100%;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
  font: inherit;
  padding: 12px;
}

.contact-form textarea,
.admin-panel textarea {
  resize: vertical;
}

#contact-status,
#admin-status {
  margin: 0;
  color: var(--accent);
  font-weight: 800;
}

footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 28px clamp(20px, 6vw, 84px);
  background: #050606;
  color: rgba(255, 255, 255, 0.56);
}

.admin-page {
  background: #090b0c;
}

.admin-shell {
  width: min(1100px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0 80px;
}

.admin-panel {
  display: grid;
  gap: 18px;
  margin-bottom: 18px;
  padding: 22px;
  border: 1px solid var(--line);
  background: #111719;
}

.admin-panel h1,
.admin-panel h2 {
  margin: 0;
}

.admin-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.work-editor,
.contact-list {
  display: grid;
  gap: 12px;
}

.work-edit-card,
.contact-list article {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
}

.check-row {
  display: flex !important;
  grid-template-columns: auto 1fr;
  align-items: center;
}

.admin-actions {
  position: sticky;
  bottom: 0;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  background: #090b0c;
}

footer img {
  width: auto;
  height: 58px;
  filter: brightness(0) invert(1);
}

footer p {
  margin: 0;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

@media (max-width: 980px) {
  .site-header {
    align-items: flex-start;
    gap: 18px;
  }

  nav {
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 10px 18px;
  }

  .about-section,
  .showreel-section {
    grid-template-columns: 1fr;
  }

  .about-visual {
    min-height: 360px;
  }

  .about-visual img {
    min-height: 360px;
  }

  .service-grid,
  .contact-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .work-gallery {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .site-header {
    position: absolute;
    min-height: 0;
    padding: 18px;
  }

  .brand img {
    width: auto;
    height: 52px;
  }

  nav {
    display: none;
  }

  .language-switch {
    margin-left: auto;
  }

  .hero {
    min-height: 54vh;
  }

  .intro-flash img {
    width: min(280px, 76vw);
  }

  .hero-statement {
    padding: 42px 20px 44px;
  }

  h1 {
    font-size: clamp(34px, 10.8vw, 52px);
  }

  .hero-actions {
    display: grid;
    grid-template-columns: 1fr;
  }

  .button {
    width: 100%;
  }

  .stats,
  .service-grid,
  .contact-grid,
  .address-row,
  .contact-form {
    grid-template-columns: 1fr;
  }

  .stats div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .stats div:last-child {
    border-bottom: 0;
  }

  .service-grid article {
    min-height: 250px;
  }

  .work-gallery {
    display: block;
    padding: 0 0 8px;
  }

  figure,
  figure img {
    min-height: 300px;
  }

  footer {
    align-items: flex-start;
    flex-direction: column;
  }
}
