/* Destroy the Kraken — portfolio
   Accent 1 Foam #649678 · Accent 2 Purple #B4A0D2 · Cream text #F8F5EE
   (from DTK-branding.png only) */

:root {
  --void: #050508;
  --ink: #f8f5ee;
  --muted: #b4b0a8;
  --subtle: #7a766e;
  --accent: #649678;
  --accent-rgb: 100, 150, 120;
  --accent-2: #b4a0d2;
  --accent-2-rgb: 180, 160, 210;
  --panel: rgba(10, 12, 16, 0.55);
  --panel-border: rgba(244, 239, 230, 0.1);
  --radius: 1.25rem;
  --font: "Figtree", system-ui, sans-serif;
  --display: "Fraunces", Georgia, serif;
  --max: 72rem;
  --pad: clamp(1.25rem, 4vw, 3rem);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100dvh;
  font-family: var(--font);
  color: var(--ink);
  background: var(--void);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* Fixed atmospheric background */
.sky {
  position: fixed;
  inset: 0;
  z-index: -2;
  background: var(--void) center / cover no-repeat url("img/bg-underwater.jpg");
  filter: blur(1.5px) saturate(0.95);
  transform: scale(1.04);
}

.sky-veil {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 80% 50% at 20% 30%, rgba(var(--accent-2-rgb), 0.1), transparent 55%),
    radial-gradient(ellipse 60% 40% at 85% 70%, rgba(var(--accent-rgb), 0.12), transparent 50%),
    linear-gradient(to bottom, rgba(5, 5, 8, 0.35), rgba(5, 5, 8, 0.72) 55%, rgba(5, 5, 8, 0.88));
}

a {
  color: var(--accent-2);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--ink);
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--accent);
  color: #fff;
  padding: 0.5rem 1rem;
  z-index: 100;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}

.wrap {
  width: min(100% - 2 * var(--pad), var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  backdrop-filter: blur(14px);
  background: rgba(5, 5, 8, 0.55);
  border-bottom: 1px solid var(--panel-border);
}

.site-header .inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
  color: inherit;
}

.brand img {
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 0.45rem;
  object-fit: cover;
  background: #323232;
}

.brand-name {
  font-family: var(--display);
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.brand-tag {
  display: block;
  font-size: 0.7rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--subtle);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
  align-items: center;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.95rem;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--ink);
}

@media (max-width: 760px) {
  .site-header .inner {
    flex-wrap: wrap;
    align-items: flex-start;
    padding-block: 0.75rem;
  }

  .brand {
    flex: 1 1 12rem;
  }

  .brand-name {
    white-space: nowrap;
  }

  .nav {
    flex: 1 1 100%;
    gap: 0.35rem 0.9rem;
  }
}

.nav-cta {
  color: var(--accent) !important;
  font-weight: 600;
}

/* Typography / sections */
.eyebrow {
  margin: 0 0 0.75rem;
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
}

h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 550;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

h1 {
  font-size: clamp(2.5rem, 7vw, 4.75rem);
  margin: 0 0 1.25rem;
  max-width: 14ch;
}

h2 {
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  margin: 0 0 1rem;
}

h3 {
  font-size: 1.35rem;
  margin: 0 0 0.5rem;
}

.lead {
  font-size: clamp(1.1rem, 2.2vw, 1.35rem);
  color: var(--muted);
  max-width: 36rem;
  margin: 0 0 2rem;
}

.muted {
  color: var(--muted);
}

.section {
  padding: clamp(4.5rem, 12vw, 9rem) 0;
}

.section-tight {
  padding: clamp(3rem, 8vw, 5rem) 0;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  padding: clamp(1.25rem, 3vw, 2rem);
  backdrop-filter: blur(10px);
  transition:
    border-color 0.22s ease,
    box-shadow 0.22s ease,
    transform 0.22s ease,
    background-color 0.22s ease;
}

.panel:hover {
  border-color: rgba(var(--accent-rgb), 0.45);
  box-shadow:
    0 0 0 1px rgba(var(--accent-rgb), 0.2),
    0 0 22px rgba(var(--accent-rgb), 0.18),
    0 0 18px rgba(var(--accent-2-rgb), 0.12);
  transform: translateY(-2px);
}

.door .btn {
  transition: transform 0.2s ease, box-shadow 0.22s ease, border-color 0.2s ease;
}

.door .btn:hover {
  box-shadow:
    0 0 0 1px rgba(var(--accent-rgb), 0.35),
    0 0 20px rgba(var(--accent-rgb), 0.25),
    0 0 16px rgba(var(--accent-2-rgb), 0.15);
}

@media (prefers-reduced-motion: reduce) {
  .panel,
  .chip,
  .door .btn,
  .btn {
    transition: none;
  }
  .panel:hover,
  .door .btn:hover {
    transform: none;
  }
}

/* Buttons */
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.75rem 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.75rem;
  padding: 0.65rem 1.2rem;
  border-radius: 999px;
  border: 1px solid transparent;
  font: inherit;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 0 1px rgba(var(--accent-rgb), 0.40), 0 0 22px rgba(var(--accent-rgb), 0.28);
}

.btn-primary:hover {
  color: #fff;
}

.btn-secondary {
  background: transparent;
  color: var(--accent-2);
  border-color: rgba(var(--accent-2-rgb), 0.5);
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  border-color: var(--panel-border);
}

/* Work cards */
.work-grid {
  display: grid;
  gap: 1.5rem;
  margin-top: 2.5rem;
}

@media (min-width: 840px) {
  .work-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

.work-card h3 {
  color: var(--ink);
}

.work-card p {
  margin: 0 0 1rem;
  color: var(--muted);
}

.work-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.chip {
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent-2);
  border: 1px solid rgba(var(--accent-2-rgb), 0.4);
  border-radius: 999px;
  padding: 0.25rem 0.65rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, color 0.2s ease;
}

.chip:hover {
  box-shadow: 0 0 12px rgba(var(--accent-2-rgb), 0.35);
}

.work-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  font-size: 0.95rem;
}

/* Scroll reveal type */
.reveal {
  opacity: 0;
  transform: translateY(1.25rem);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in {
  opacity: 1;
  transform: none;
}

/* Contact / about */
.prose {
  max-width: 40rem;
}

.prose p {
  color: var(--muted);
}

.prose strong {
  color: var(--ink);
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 2rem 0;
}

.contact-list li {
  margin: 0 0 1rem;
}

.contact-list a {
  font-size: 1.15rem;
}

.note {
  font-size: 0.95rem;
  color: var(--muted);
  max-width: 34rem;
}

footer.site-footer {
  border-top: 1px solid var(--panel-border);
  padding: 2.5rem 0 3.5rem;
  color: var(--subtle);
  font-size: 0.85rem;
}

footer.site-footer a {
  color: var(--muted);
  margin-right: 1rem;
}

.photo {
  width: min(220px, 55vw);
  height: auto;
  border-radius: 1rem;
  display: block;
  margin: 0 0 1.75rem;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.45);
  border: 1px solid var(--panel-border);
}

/* Single-screen home — no scroll */
.page-home {
  overflow: hidden;
  height: 100dvh;
}

.page-home .home-main {
  display: flex;
  align-items: center;
  min-height: calc(100dvh - 4rem);
  padding: var(--pad) 0;
}

.page-home .home-hero {
  width: min(100% - 2 * var(--pad), var(--max));
}

.page-home h1 {
  max-width: 22ch;
  font-size: clamp(2.15rem, 5.2vw, 3.75rem);
}

/* Dual-purpose home: doors + proof cards (home may scroll) */
.page-home {
  overflow: auto;
  height: auto;
}

.page-home .home-main {
  display: block;
  min-height: 0;
  padding: 0;
}

.door-row {
  display: grid;
  gap: 0.85rem;
  margin: 1.75rem 0 0.5rem;
}

@media (min-width: 720px) {
  .door-row {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }
}

.door {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  align-items: flex-start;
}

.door-hint {
  margin: 0;
  font-size: 0.85rem;
  color: var(--subtle);
}

.proof-grid {
  display: grid;
  gap: 1.25rem;
  margin-top: 1.5rem;
}

@media (min-width: 840px) {
  .proof-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.35rem;
  }
}

.proof-grid h3 {
  margin-top: 0;
}

.shelf {
  margin-top: 3.5rem;
}

.shelf-intro {
  color: var(--muted);
  max-width: 40rem;
  margin: 0 0 1.5rem;
}

.path-box {
  margin-top: 2.5rem;
}

.intent-grid {
  display: grid;
  gap: 1.25rem;
  margin: 2rem 0;
}

@media (min-width: 840px) {
  .intent-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.intent-grid h3 {
  margin-top: 0;
}

/* Product pricing and spec lists */
.callout {
  margin: 0 0 1.75rem;
  padding: 0.15rem 0 0.15rem 1rem;
  border-left: 3px solid var(--accent);
  color: var(--muted);
  max-width: 42rem;
}

.spec-list {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--muted);
}

.spec-list li {
  margin: 0.4rem 0;
}

.spec-list li::marker {
  color: var(--accent);
}

.table-wrap {
  overflow: auto;
  max-inline-size: 100%;
  margin: 1.25rem 0 0;
  container-type: inline-size;
}

.price-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.95rem;
  --label-2: "Price";
  --label-3: "Hardware";
  --label-4: "Included";
}

.price-table caption {
  caption-side: bottom;
  text-align: left;
  color: var(--subtle);
  font-size: 0.85rem;
  padding-top: 0.75rem;
}

.price-table th,
.price-table td {
  text-align: left;
  vertical-align: top;
  padding: 0.9rem 1rem;
  border-bottom: 1px solid var(--panel-border);
  background: #141614;
}

.price-table td {
  color: var(--muted);
}

.price-table thead th {
  position: sticky;
  inset-block-start: 0;
  z-index: 2;
  color: var(--accent);
  font-family: var(--font);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.price-table tbody th {
  position: sticky;
  inset-inline-start: 0;
  z-index: 1;
  color: var(--ink);
  font-family: var(--display);
  font-weight: 550;
  min-inline-size: 11rem;
}

@container (width < 720px) {
  .price-table {
    display: flex;
    flex-direction: column;
  }

  .price-table caption {
    display: block;
    inline-size: 100%;
    order: 2;
    padding-top: 0.25rem;
  }

  .price-table thead,
  .price-table tbody,
  .price-table tr,
  .price-table th,
  .price-table td {
    display: block;
  }

  .price-table tbody {
    order: 1;
  }

  .price-table thead {
    display: none;
  }

  .price-table tr {
    margin-block-end: 1rem;
    border: 1px solid var(--panel-border);
    border-radius: var(--radius);
    overflow: hidden;
  }

  .price-table tbody th {
    position: sticky;
    inset-block-start: 0;
    inset-inline-start: auto;
    z-index: 2;
  }

  .price-table td:nth-child(2)::before,
  .price-table td:nth-child(3)::before,
  .price-table td:nth-child(4)::before {
    display: block;
    margin-bottom: 0.25rem;
    font-family: var(--font);
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--accent);
  }

  .price-table td:nth-child(2)::before {
    content: var(--label-2) ": " / var(--label-2);
  }

  .price-table td:nth-child(3)::before {
    content: var(--label-3) ": " / var(--label-3);
  }

  .price-table td:nth-child(4)::before {
    content: var(--label-4) ": " / var(--label-4);
  }
}

/* Contact form */
.inquiry-form {
  display: grid;
  gap: 1rem;
  margin-top: 1.5rem;
  max-width: 40rem;
}

.inquiry-form label,
.inquiry-form legend {
  display: block;
  margin-bottom: 0.35rem;
  font-size: 0.95rem;
}

.inquiry-form input[type="text"],
.inquiry-form input[type="email"],
.inquiry-form input[type="tel"],
.inquiry-form textarea {
  width: 100%;
  margin: 0;
  padding: 0.7rem 0.8rem;
  font: inherit;
  color: var(--ink);
  background: rgba(5, 5, 8, 0.55);
  border: 1px solid var(--panel-border);
  border-radius: 0.7rem;
}

.inquiry-form textarea {
  min-height: 9rem;
  resize: vertical;
}

.inquiry-form fieldset {
  margin: 0;
  padding: 0.9rem 1rem;
  border: 1px solid var(--panel-border);
  border-radius: 0.7rem;
}

.choice-row {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 1.5rem;
}

.choice-row label {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  margin: 0;
}

.req {
  color: var(--accent);
}

.form-disclaimer {
  margin: 1rem 0 0;
  max-width: 40rem;
  color: var(--muted);
}

/* Homepage services — titles first, detail on open */
.page-home .hero {
  padding-bottom: clamp(1.5rem, 4vw, 2.75rem);
}

.service-list {
  display: grid;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

@media (min-width: 840px) {
  .service-list {
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
  }
}

.service {
  background: rgba(10, 12, 16, 0.72);
  border: 1px solid var(--panel-border);
  border-radius: var(--radius);
  color: var(--ink);
}

.service summary {
  cursor: pointer;
  list-style: none;
  padding: 1rem 1.15rem;
  font-family: var(--display);
  font-size: 1.2rem;
  letter-spacing: -0.02em;
}

.service summary::-webkit-details-marker {
  display: none;
}

.service summary::after {
  content: "+";
  float: inline-end;
  color: var(--accent);
  font-family: var(--font);
  font-weight: 600;
}

.service[open] summary::after {
  content: "–";
}

.service summary:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.service-body {
  margin: 0;
  padding: 0 1.15rem 1.15rem;
  color: var(--muted);
}

@media (prefers-reduced-motion: no-preference) {
  .service[open] .service-body {
    animation: service-in 0.22s ease;
  }
}

@keyframes service-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .service[open] .service-body {
    animation: none;
  }
}
