/* apps.buknal.com. A short studio portfolio page: one intro sentence, one coloured tile per
   app, a fine-rule footer. Layout follows Replay's "small studio product portfolio"
   (replay.software, via Refero): white canvas, black text, colour only inside the app tiles,
   system sans throughout, 16px tile corners, 1264px container with 32px side padding.
   System fonts only, no scripts, no third-party requests. */

:root {
  --ground: #ffffff;
  --ink: #000000;
  --ink-soft: #333333;
  --muted: #6b6b6b;      /* Replay uses #808080; darkened to pass 4.5:1 for 16px text */
  --rule: #f3f4f6;
  --focus: #d93a3a;      /* Buknal coral, focus rings only */

  --font: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.4, 0, 0.2, 1);

  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ground: #0e1310;
    --ink: #f2f4f2;
    --ink-soft: #d0d6d1;
    --muted: #9aa49c;
    --rule: #232b25;
    --focus: #ff5757;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 16px/1.5 var(--font);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 4px; }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.wrap {
  max-width: 1264px;
  margin: 0 auto;
  padding: 0 clamp(16px, 2.5vw, 32px) 80px;
}

/* Header */
.site-header { padding-top: clamp(32px, 5vw, 64px); }
.brand { display: inline-flex; align-items: center; min-height: 44px; }
.brand img { display: block; width: 61px; height: 40px; }

/* Studio introduction */
.intro {
  margin: clamp(40px, 5vw, 64px) 0 0;
  max-width: 22ch;
  font-size: clamp(26px, 2.6vw, 36px);
  line-height: 1.15;
  font-weight: 500;
  text-wrap: balance;
}

/* App tiles */
.apps {
  list-style: none;
  margin: clamp(40px, 5vw, 64px) 0 0;
  padding: 0;
  display: grid;
  gap: 32px;
}

.tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 24px;
  padding: clamp(40px, 5vw, 64px) 24px;
  border-radius: 16px;
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.05);
  color: #ffffff;
  text-align: center;
  text-decoration: none;
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease);
}
.tile:hover {
  transform: translateY(-4px);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, 0.05), 0 20px 25px -5px rgba(0, 0, 0, 0.12), 0 8px 10px -6px rgba(0, 0, 0, 0.08);
}

.tile-tavbi { background: linear-gradient(to top right, #092725, #17766b); }

.tile-id {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: clamp(20px, 3vw, 40px);
}

.tile-icon {
  display: block;
  width: clamp(112px, 17vw, 248px);
  height: auto;
  aspect-ratio: 1;
  border-radius: 22.5%;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.12), 0 20px 40px -12px rgba(0, 0, 0, 0.45);
}

.tile-name {
  font-size: clamp(48px, 5vw, 72px);
  line-height: 1;
  font-weight: 600;
  letter-spacing: -0.025em;
  color: #ffffff;
  background: linear-gradient(to bottom, #ffffff, #c9efe5);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.tile-promise {
  max-width: 28ch;
  font-size: clamp(18px, 1.8vw, 24px);
  line-height: 1.33;
  color: #e6f7f2;
  text-wrap: balance;
}

.tile-platform {
  display: inline-flex;
  align-items: center;
  height: 30px;
  padding: 0 14px;
  border-radius: 9999px;
  background: rgba(255, 255, 255, 0.14);
  font-size: 14px;
  font-weight: 600;
}

/* Footer */
.site-footer {
  margin-top: clamp(64px, 8vw, 96px);
  padding-top: 64px;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 32px;
  color: var(--muted);
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 0 24px; }
.site-footer nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 0.15s var(--ease);
}
.site-footer nav a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 0.18em; }

@media (prefers-reduced-motion: reduce) {
  .tile, .site-footer nav a { transition: none; }
  .tile:hover { transform: none; }
}
