/* ── Design Tokens ────────────────────────────────────── */
:root {
  /* Type scale */
  --text-xs:   clamp(0.7rem,  0.65rem + 0.2vw,  0.8rem);
  --text-sm:   clamp(0.8rem,  0.75rem + 0.25vw, 0.9rem);
  --text-base: clamp(0.9rem,  0.85rem + 0.25vw, 1rem);
  --text-lg:   clamp(1rem,    0.9rem  + 0.5vw,  1.25rem);
  --text-xl:   clamp(1.25rem, 1rem    + 1vw,    1.75rem);
  --text-2xl:  clamp(1.5rem,  1rem    + 2vw,    2.25rem);

  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-10: 2.5rem;
  --space-12: 3rem;

  /* Radii */
  --radius-sm: 0.375rem;
  --radius-md: 0.625rem;
  --radius-lg: 1rem;
  --radius-full: 9999px;

  /* Transition */
  --transition: 180ms cubic-bezier(0.16, 1, 0.3, 1);

  /* TAW Brand palette — always dark */
  --color-bg:          #0E1013;
  --color-surface:     #1C1E22;
  --color-surface-2:   #23262B;
  --color-border:      #2E333A;
  --color-border-subtle: rgba(200,205,214,0.08);
  --color-text:        #C8CDD6;
  --color-text-muted:  #7A8294;
  --color-text-faint:  #454C58;
  --color-accent:      #A07040;
  --color-accent-hover:#B8864E;
  --color-accent-glow: rgba(160, 112, 64, 0.15);
  --color-silver:      #C8CDD6;

  /* Fonts */
  --font-display: 'Cabinet Grotesk', 'Trebuchet MS', sans-serif;
  --font-body:    'Satoshi', 'Calibri', sans-serif;
}

/* ── Page Shell ──────────────────────────────────────── */
body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  min-height: 100dvh;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: var(--space-8) var(--space-4);
}

.page {
  position: relative;
  width: 100%;
  max-width: 560px;
  z-index: 1;
}

/* ── Background Texture ─────────────────────────────── */
.bg-texture {
  position: fixed;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(160,112,64,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 60% 40% at 50% 100%, rgba(28,30,34,0.8) 0%, transparent 80%);
  z-index: 0;
  pointer-events: none;
}

/* Subtle noise grain */
.bg-texture::after {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.035'/%3E%3C/svg%3E");
  background-size: 256px 256px;
  opacity: 0.4;
  pointer-events: none;
}

/* ── Background Emblem Watermark ────────────────────── */
.bg-emblem {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(600px, 110vw);
  height: min(600px, 110vw);
  opacity: 0.025;
  filter: grayscale(100%);
  pointer-events: none;
  z-index: 0;
}
.bg-emblem img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

/* ── Card ────────────────────────────────────────────── */
.card {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-6);
  padding: 0 var(--space-6) var(--space-6);
  background: rgba(28, 30, 34, 0.6);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(200,205,214,0.04) inset,
    0 24px 64px rgba(0,0,0,0.5),
    0 0 120px rgba(160,112,64,0.04);
}

/* ── Identity Header with Emblem Watermark ──────────── */
.identity-header {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-block: var(--space-8) var(--space-4);
  overflow: visible;
}

.emblem-bg {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  z-index: 0;
}

.emblem-bg img {
  width: 300px;
  height: auto;
  object-fit: contain;
  opacity: 0.12;
  filter: grayscale(20%) brightness(1.15);
  transform: translateY(25%);
  -webkit-mask-image: radial-gradient(ellipse 80% 60% at 50% 35%, black 15%, rgba(0,0,0,0.5) 50%, transparent 80%);
  mask-image: radial-gradient(ellipse 80% 60% at 50% 35%, black 15%, rgba(0,0,0,0.5) 50%, transparent 80%);
}

/* ── Identity ────────────────────────────────────────── */
.identity {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: var(--space-2);
  text-align: center;
}

.company-name {
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--color-silver);
  text-transform: uppercase;
  line-height: 1.1;
}

.company-name .llc {
  font-size: 0.55em;
  font-weight: 700;
  opacity: 0.7;
  letter-spacing: 0.05em;
  vertical-align: middle;
  margin-left: 0.2em;
}

.tagline {
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--color-accent);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.ethos {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  letter-spacing: 0.02em;
}

.badge {
  display: inline-block;
  margin-top: var(--space-1);
  padding: var(--space-1) var(--space-3);
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--color-accent);
  background: rgba(160,112,64,0.1);
  border: 1px solid rgba(160,112,64,0.25);
  border-radius: var(--radius-full);
}

/* ── Links ───────────────────────────────────────────── */
.links {
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  width: 100%;
}

.link-card {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  text-decoration: none;
  color: var(--color-text);
  transition:
    background var(--transition),
    border-color var(--transition),
    box-shadow var(--transition),
    transform var(--transition);
  cursor: pointer;
}

.link-card:hover,
.link-card:focus-visible {
  background: rgba(160,112,64,0.07);
  border-color: rgba(160,112,64,0.35);
  box-shadow: 0 0 24px rgba(160,112,64,0.08), 0 4px 12px rgba(0,0,0,0.25);
  transform: translateY(-1px);
}

.link-card:active {
  transform: translateY(0);
}

/* Primary CTA (website) — slightly elevated */
.link-primary {
  background: rgba(160,112,64,0.06);
  border-color: rgba(160,112,64,0.3);
}

.link-primary:hover {
  background: rgba(160,112,64,0.12);
  border-color: rgba(160,112,64,0.5);
}

/* Doc download */
.link-doc {
  border-style: dashed;
  border-color: rgba(200,205,214,0.12);
}

.link-doc:hover {
  border-style: solid;
  border-color: rgba(160,112,64,0.35);
}

/* Icon */
.link-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
  opacity: 0.9;
}

.link-icon svg {
  width: 20px;
  height: 20px;
}

/* Text block */
.link-text {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.link-label {
  font-family: var(--font-display);
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--color-silver);
  line-height: 1.2;
}

.link-sub {
  font-size: var(--text-xs);
  color: var(--color-text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Arrow */
.link-arrow {
  flex-shrink: 0;
  width: 16px;
  height: 16px;
  color: var(--color-text-faint);
  transition: color var(--transition), transform var(--transition);
}

.link-arrow svg {
  width: 16px;
  height: 16px;
}

.link-card:hover .link-arrow {
  color: var(--color-accent);
  transform: translate(2px, -2px);
}

/* ── Footer ──────────────────────────────────────────── */
.foot {
  text-align: center;
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  padding-top: var(--space-2);
  border-top: 1px solid var(--color-border-subtle);
  width: 100%;
}

.foot p {
  font-size: var(--text-xs);
  color: var(--color-text-faint);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  max-width: 100%;
}

/* ── Entrance Animation ──────────────────────────────── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}

.card {
  animation: fadeUp 0.5s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.logo-wrap  { animation: fadeUp 0.5s 0.05s cubic-bezier(0.16, 1, 0.3, 1) both; }
.identity   { animation: fadeUp 0.5s 0.1s  cubic-bezier(0.16, 1, 0.3, 1) both; }

.link-card:nth-child(1) { animation: fadeUp 0.4s 0.15s cubic-bezier(0.16, 1, 0.3, 1) both; }
.link-card:nth-child(2) { animation: fadeUp 0.4s 0.20s cubic-bezier(0.16, 1, 0.3, 1) both; }
.link-card:nth-child(3) { animation: fadeUp 0.4s 0.25s cubic-bezier(0.16, 1, 0.3, 1) both; }
.link-card:nth-child(4) { animation: fadeUp 0.4s 0.30s cubic-bezier(0.16, 1, 0.3, 1) both; }
.link-card:nth-child(5) { animation: fadeUp 0.4s 0.35s cubic-bezier(0.16, 1, 0.3, 1) both; }
.link-card:nth-child(6) { animation: fadeUp 0.4s 0.40s cubic-bezier(0.16, 1, 0.3, 1) both; }
.link-card:nth-child(7) { animation: fadeUp 0.4s 0.45s cubic-bezier(0.16, 1, 0.3, 1) both; }

.foot { animation: fadeUp 0.4s 0.5s cubic-bezier(0.16, 1, 0.3, 1) both; }

/* ── Mobile ──────────────────────────────────────────── */
@media (max-width: 480px) {
  body { padding: var(--space-4) var(--space-3); }
  .card { padding: var(--space-6) var(--space-4) var(--space-5); gap: var(--space-5); }
  .link-card { padding: var(--space-3) var(--space-4); gap: var(--space-3); }
  .link-sub { font-size: 0.65rem; }
}
