/* ==========================================================================
   DiBLAT Inc. — Official Website
   Design reference: reference_by_designer/DiBLAT-Inc.jpg (1920px canvas / 1280px container)
   ========================================================================== */

/* ----- Tokens ----- */
:root {
  --c-bg: #000000;
  --c-panel: #060a0d;
  --c-text: #f2f4f6;
  --c-text-dim: #b7bdc3;
  --c-text-faint: #7d848b;
  --c-line: #2a2f34;
  --c-accent: #17c4ff;          /* cyan point color */
  --c-accent-soft: rgba(23, 196, 255, 0.45);
  --c-accent-glow: rgba(23, 196, 255, 0.18);
  --c-green: #35dd9c;           /* Diclops / 출원 badge */
  --container: 1280px;
  --header-h: 68px;
  --font: "Pretendard Variable", Pretendard, -apple-system, BlinkMacSystemFont,
          "Segoe UI", Roboto, "Helvetica Neue", "Apple SD Gothic Neo",
          "Noto Sans KR", sans-serif;
}

/* ----- Reset / base ----- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background: var(--c-bg);
  color: var(--c-text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; }
button { font-family: inherit; cursor: pointer; background: none; border: 0; color: inherit; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

.pc-only { display: inline; }
.accent { color: var(--c-accent); }
.arrow { display: inline-block; transition: transform 0.25s ease; }

section[id], div[id="who-we-are"] { scroll-margin-top: var(--header-h); }

/* ----- Reveal on scroll ----- */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ==========================================================================
   Header
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--c-line);
}
.header-inner {
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.brand {
  font-size: 1.375rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  white-space: nowrap;
}
.gnb {
  display: flex;
  align-items: center;
  gap: clamp(20px, 3.4vw, 56px);
}
.gnb a {
  font-size: 0.9375rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--c-text);
  transition: color 0.2s ease;
}
.gnb a:hover { color: var(--c-accent); }
.gnb-contact { color: var(--c-accent) !important; }
.gnb-contact:hover .arrow { transform: translateX(4px); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 40px;
  height: 40px;
  padding: 8px;
}
.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--c-text);
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ==========================================================================
   Sections (common)
   ========================================================================== */
.section { padding: clamp(96px, 12vw, 180px) 0; border-bottom: 1px solid #17191b; }

.section-title {
  font-size: clamp(2.5rem, 5.5vw, 4.5rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.02em;
}
.section-desc {
  margin-top: 28px;
  color: var(--c-text-dim);
  font-size: 1.0625rem;
}

/* ==========================================================================
   Hero
   ========================================================================== */
.hero {
  min-height: calc(100vh - var(--header-h));
  display: flex;
  align-items: center;
  padding: clamp(80px, 10vw, 140px) 0;
}
.hero-title {
  font-size: clamp(3.25rem, 10.5vw, 10rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.03em;
}
.hero-sub {
  margin-top: clamp(28px, 4vw, 56px);
  font-size: 1.25rem;
  font-weight: 700;
}
.hero-desc {
  margin-top: 20px;
  color: var(--c-text-dim);
  font-size: 1.0625rem;
  line-height: 1.75;
}
.hero-actions {
  margin-top: clamp(36px, 4.5vw, 60px);
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

/* ----- Buttons ----- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 28px;
  border-radius: 6px;
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn:hover .arrow { transform: translateX(4px); }
.btn-fill {
  background: var(--c-accent);
  color: #001018;
  box-shadow: 0 0 24px var(--c-accent-glow);
}
.btn-fill:hover { box-shadow: 0 0 36px var(--c-accent-soft); }
.btn-line {
  border: 1px solid var(--c-accent);
  color: var(--c-accent);
}
.btn-line:hover { background: rgba(23, 196, 255, 0.08); }

/* ==========================================================================
   Who We Are
   ========================================================================== */
.who-grid {
  margin-top: clamp(56px, 7vw, 110px);
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: clamp(40px, 6vw, 100px);
  align-items: center;
}
.who-logo { display: flex; justify-content: center; }
.who-logo img { width: clamp(180px, 22vw, 300px); }
.who-body h3 { font-size: 1.375rem; font-weight: 700; }
.who-body p { margin-top: 18px; color: var(--c-text-dim); line-height: 1.8; }
.tag-list {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.tag-list li {
  border: 1px solid var(--c-accent);
  color: var(--c-accent);
  font-size: 0.875rem;
  font-weight: 600;
  padding: 8px 16px;
  border-radius: 4px;
}

/* ==========================================================================
   Mission
   ========================================================================== */
.mission-copy {
  font-size: clamp(1.875rem, 4.6vw, 3.75rem);
  font-weight: 800;
  line-height: 1.35;
  letter-spacing: -0.02em;
}
.mission-foot { margin-top: clamp(64px, 8vw, 120px); }
.mission-foot h3 { font-size: 1.375rem; font-weight: 700; }
.mission-foot p { margin-top: 16px; color: var(--c-text-dim); }

/* ==========================================================================
   Core Technologies
   ========================================================================== */
.card-grid {
  margin-top: clamp(56px, 7vw, 110px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  max-width: 1080px;
  margin-left: auto;
  margin-right: auto;
}
.tech-card {
  background: var(--c-panel);
  border: 1px solid var(--c-accent-soft);
  border-radius: 10px;
  padding: 36px 32px;
  box-shadow: 0 0 22px var(--c-accent-glow);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.tech-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 40px var(--c-accent-soft);
}
.tech-card .num { font-size: 1.125rem; font-weight: 600; color: var(--c-text); }
.tech-card h3 { margin-top: 18px; font-size: 1.375rem; font-weight: 700; color: var(--c-accent); }
.tech-card p { margin-top: 14px; color: var(--c-text-dim); font-size: 0.9688rem; line-height: 1.75; }

/* ==========================================================================
   Technology Ecosystem
   ========================================================================== */
.eco-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  gap: 32px clamp(40px, 6vw, 90px);
}
.eco-lead { color: var(--c-text-dim); line-height: 1.8; padding-bottom: 8px; }

.eco-tree {
  margin-top: clamp(64px, 8vw, 120px);
  display: flex;
  flex-direction: column;
  align-items: center;
}
.eco-node {
  border: 1px solid var(--c-text-faint);
  border-radius: 8px;
  padding: 18px 34px;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.04em;
  text-align: center;
  background: var(--c-bg);
}
.eco-root {
  background: var(--c-accent);
  border-color: var(--c-accent);
  color: #001018;
  box-shadow: 0 0 32px var(--c-accent-soft);
}
.eco-platform { font-size: 1.125rem; padding: 20px 44px; }
.eco-diclops {
  background: var(--c-green);
  border-color: var(--c-green);
  color: #002417;
  box-shadow: 0 0 32px rgba(53, 221, 156, 0.4);
}
.eco-connector { width: 1px; height: 44px; background: var(--c-text-faint); }
.eco-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
  width: min(100%, 780px);
  position: relative;
  padding-top: 24px;
}
/* horizontal bracket connecting the three columns */
.eco-row::before {
  content: "";
  position: absolute;
  top: 0;
  left: 16.66%;
  right: 16.66%;
  border-top: 1px solid var(--c-text-faint);
}
.eco-row .eco-node {
  border-radius: 0;
  padding: 18px 10px;
  font-size: 0.9375rem;
  position: relative;
}
.eco-row .eco-node::before {
  content: "";
  position: absolute;
  top: -24px;
  left: 50%;
  height: 24px;
  border-left: 1px solid var(--c-text-faint);
}
.eco-row .eco-node + .eco-node { border-left: 0; }

/* ==========================================================================
   Diclops
   ========================================================================== */
.diclops-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: clamp(48px, 6vw, 100px);
  align-items: center;
}
.badge-soon {
  display: inline-block;
  border: 1px solid var(--c-accent);
  color: var(--c-accent);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.22em;
  padding: 10px 22px;
  border-radius: 4px;
}
.diclops-logo { margin-top: clamp(40px, 5vw, 80px); width: clamp(220px, 24vw, 380px); }
.diclops-intro h3 { margin-top: clamp(32px, 4vw, 60px); font-size: 1.5rem; font-weight: 700; }
.diclops-intro p { margin-top: 18px; color: var(--c-text-dim); line-height: 1.8; }

.diclops-features {
  background: var(--c-panel);
  border: 1px solid var(--c-accent-soft);
  border-radius: 12px;
  box-shadow: 0 0 28px var(--c-accent-glow);
  padding: clamp(28px, 3.5vw, 48px);
}
.diclops-features h4 {
  color: var(--c-accent);
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}
.diclops-features ol { margin-top: 12px; }
.diclops-features li {
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 20px 4px;
  border-bottom: 1px solid var(--c-line);
  font-weight: 700;
  font-size: 0.9688rem;
  letter-spacing: 0.05em;
}
.diclops-features li:last-child { border-bottom: 0; }
.diclops-features li span { color: var(--c-text-faint); font-weight: 600; }

/* ==========================================================================
   Research & Development
   ========================================================================== */
.research-lead { margin-top: clamp(40px, 5vw, 72px); }
.research-lead h3 { font-size: 1.25rem; font-weight: 700; }
.research-lead p { margin-top: 14px; color: var(--c-text-dim); }

.rnd-grid {
  margin-top: clamp(56px, 7vw, 100px);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 26px;
  max-width: 780px;
  margin-left: auto;
  margin-right: auto;
}
.rnd-item {
  border: 1px solid var(--c-accent-soft);
  border-radius: 10px;
  background: var(--c-panel);
  box-shadow: 0 0 20px var(--c-accent-glow);
  padding: 42px 16px;
  text-align: center;
  font-weight: 700;
  letter-spacing: 0.05em;
  font-size: 1rem;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.rnd-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 0 36px var(--c-accent-soft);
}

/* ==========================================================================
   Showcase
   ========================================================================== */
.filter-tabs {
  margin-top: clamp(40px, 5vw, 72px);
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.tab {
  border: 1px solid var(--c-accent);
  color: var(--c-accent);
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 12px 22px;
  border-radius: 4px;
  transition: background 0.2s ease, color 0.2s ease;
}
.tab:hover { background: rgba(23, 196, 255, 0.1); }
.tab.is-active { background: var(--c-accent); color: #001018; }

.gallery {
  margin-top: 40px;
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 10px;
}
.gallery-item { position: relative; overflow: hidden; border-radius: 4px; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; }
.item-ad { grid-column: span 7; }
.item-animation { grid-column: span 5; }
.item-scenario { grid-column: span 6; }
.item-drama { grid-column: span 6; }
.ad-strip { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 6px; height: 100%; }
.gallery-item.is-hidden { display: none; }
.gallery-empty {
  grid-column: 1 / -1;
  padding: 80px 0;
  text-align: center;
  color: var(--c-text-faint);
}

/* ==========================================================================
   News & Insights
   ========================================================================== */
.news-list { margin-top: clamp(56px, 7vw, 110px); }
.news-item {
  display: grid;
  grid-template-columns: 120px 110px 1fr;
  gap: clamp(20px, 3vw, 48px);
  align-items: start;
  padding: 36px 0;
  border-bottom: 1px solid var(--c-text-dim);
}
.news-item:first-child { padding-top: 0; }
.news-item time { color: var(--c-text-dim); font-size: 0.9688rem; padding-top: 6px; }
.news-badge {
  border: 1px solid var(--c-accent);
  color: var(--c-accent);
  font-size: 0.8125rem;
  font-weight: 700;
  text-align: center;
  padding: 7px 10px;
  border-radius: 4px;
  white-space: nowrap;
}
.news-body h3 { font-size: 1.25rem; font-weight: 700; line-height: 1.4; }
.news-body p { margin-top: 10px; color: var(--c-text-dim); font-size: 0.9688rem; }

/* ==========================================================================
   Patents
   ========================================================================== */
.patents-panel {
  margin-top: clamp(48px, 6vw, 90px);
  background: var(--c-panel);
  border: 1px solid var(--c-line);
  border-radius: 12px;
  box-shadow: 0 0 26px rgba(23, 196, 255, 0.08);
  padding: clamp(16px, 2.5vw, 40px);
}
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.patents table {
  width: 100%;
  min-width: 960px;
  border-collapse: collapse;
  font-size: 0.9375rem;
}
.patents th {
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--c-accent);
  padding: 18px 14px;
  border-bottom: 1px solid var(--c-text-dim);
  text-align: center;
  white-space: nowrap;
}
.patents td {
  padding: 20px 14px;
  border-bottom: 1px solid var(--c-line);
  text-align: center;
  white-space: nowrap;
  color: var(--c-text-dim);
}
.patents tr:last-child td { border-bottom: 0; }
.patents .t-left { text-align: left; }
.patents td.t-left { color: var(--c-text); white-space: normal; min-width: 320px; }
.patents td.t-left strong { font-weight: 800; }
.patents .t-strong { color: var(--c-text); font-weight: 700; }
.patents .t-dim { color: var(--c-text-faint); }
.status {
  display: inline-block;
  font-size: 0.8125rem;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: 3px;
}
.s-reg { background: var(--c-accent); color: #001018; }
.s-app { background: var(--c-green); color: #002417; }

/* ==========================================================================
   Contact
   ========================================================================== */
.contact { border-bottom: 0; }
.contact-grid {
  display: grid;
  grid-template-columns: 1.15fr 1fr;
  gap: clamp(48px, 6vw, 110px);
  align-items: start;
}
.contact-lead { margin-top: clamp(36px, 5vw, 72px); font-size: 1.125rem; font-weight: 600; }
.contact-info { margin-top: clamp(36px, 5vw, 64px); }
.contact-info > div {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 16px;
  padding: 12px 0;
}
.contact-info dt { font-weight: 700; }
.contact-info dd { color: var(--c-text-dim); }
.contact-info a:hover { color: var(--c-accent); }

.contact-form .form-row { margin-bottom: 24px; }
.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}
.contact-form label {
  display: block;
  font-size: 0.9375rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.contact-form input,
.contact-form textarea {
  display: block;
  width: 100%;
  margin-top: 12px;
  background: #232629;
  border: 1px solid #45494e;
  border-radius: 4px;
  color: var(--c-text);
  font-family: inherit;
  font-size: 0.9688rem;
  padding: 13px 14px;
  transition: border-color 0.2s ease;
}
.contact-form input::placeholder,
.contact-form textarea::placeholder { color: #8b9095; }
.contact-form input:focus,
.contact-form textarea:focus { outline: none; border-color: var(--c-accent); }
.contact-form textarea { resize: vertical; min-height: 160px; }
.btn-submit { width: 100%; justify-content: center; margin-top: 8px; }
.form-note { margin-top: 16px; font-size: 0.9063rem; color: var(--c-green); }
.form-note.is-error { color: #ff7a7a; }

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer { border-top: 1px solid var(--c-line); padding: 40px 0; }
.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px 40px;
}
.copyright { color: var(--c-text-dim); font-size: 0.9375rem; }
.footer-nav { display: flex; gap: clamp(24px, 3vw, 48px); }
.footer-nav a { font-size: 0.9375rem; font-weight: 600; }
.footer-nav a:hover { color: var(--c-accent); }

/* ==========================================================================
   Modal
   ========================================================================== */
.modal { position: fixed; inset: 0; z-index: 200; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, 0.82); }
.modal-body {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(92vw, 960px);
}
.modal-content {
  aspect-ratio: 16 / 9;
  background: var(--c-panel);
  border: 1px solid var(--c-accent-soft);
  border-radius: 10px;
  box-shadow: 0 0 60px var(--c-accent-glow);
  display: flex;
  align-items: center;
  justify-content: center;
}
.modal-content iframe,
.modal-content video { width: 100%; height: 100%; border: 0; border-radius: 10px; }
.modal-placeholder { color: var(--c-text-dim); font-size: 1.125rem; }
.modal-close {
  position: absolute;
  top: -48px;
  right: 0;
  font-size: 2rem;
  line-height: 1;
  color: var(--c-text);
}
.modal-close:hover { color: var(--c-accent); }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1024px) {
  .who-grid, .diclops-grid, .contact-grid { grid-template-columns: 1fr; }
  .who-logo { justify-content: flex-start; }
  .news-item { grid-template-columns: 110px 1fr; }
  .news-item .news-body { grid-column: 1 / -1; }
}

@media (max-width: 768px) {
  .pc-only { display: none; }

  .nav-toggle { display: flex; }
  .gnb {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    background: rgba(0, 0, 0, 0.97);
    border-bottom: 1px solid var(--c-line);
    padding: 8px 24px 20px;
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: transform 0.25s ease, opacity 0.25s ease, visibility 0.25s;
  }
  .gnb.is-open { transform: none; opacity: 1; visibility: visible; }
  .gnb a { padding: 14px 0; width: 100%; border-bottom: 1px solid #141618; }
  .gnb a:last-child { border-bottom: 0; }

  .card-grid, .rnd-grid, .form-row-2 { grid-template-columns: 1fr; }

  .eco-row { grid-template-columns: 1fr; width: min(100%, 360px); padding-top: 0; }
  .eco-row::before { display: none; }
  .eco-row .eco-node { border-radius: 8px; }
  .eco-row .eco-node::before { display: none; }
  .eco-row .eco-node + .eco-node { border-left: 1px solid var(--c-text-faint); margin-top: 16px; }

  .gallery { grid-template-columns: 1fr; }
  .item-ad, .item-animation, .item-scenario, .item-drama { grid-column: 1 / -1; }

  .news-item { grid-template-columns: 1fr; gap: 12px; }
  .news-badge { justify-self: start; }

  .contact-info > div { grid-template-columns: 1fr; gap: 4px; }

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