/* ============================================================
   A440.ORG — Main Stylesheet
   Shared across landing page and /steve/
   ============================================================ */

/* ── Design Tokens ──────────────────────────────────────────── */
:root {
  /* Palette */
  --color-bg:           #0d0d0d;
  --color-surface:      #161616;
  --color-surface-2:    #1f1f1f;
  --color-border:       rgba(255, 255, 255, 0.08);
  --color-border-mid:   rgba(255, 255, 255, 0.14);

  --color-text:         #f0ece4;        /* warm off-white */
  --color-text-muted:   rgba(240, 236, 228, 0.55);
  --color-text-faint:   rgba(240, 236, 228, 0.30);

  --color-amber:        #B07D2A;        /* shared with Brede Logic */
  --color-amber-light:  #d4a44e;
  --color-amber-glow:   rgba(176, 125, 42, 0.18);

  /* Typography */
  --font-heading: 'Lora', Georgia, 'Times New Roman', serif;
  --font-body:    'Inter', -apple-system, BlinkMacSystemFont, sans-serif;

  /* Type scale */
  --text-xs:   0.75rem;
  --text-sm:   0.875rem;
  --text-base: 1rem;
  --text-lg:   1.125rem;
  --text-xl:   1.25rem;
  --text-2xl:  1.5rem;
  --text-3xl:  1.875rem;
  --text-4xl:  2.25rem;
  --text-5xl:  3rem;
  --text-6xl:  3.75rem;

  /* Spacing (4px base) */
  --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;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;

  /* Layout */
  --max-width:    1100px;
  --card-radius:  12px;

  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 260ms ease;
  --transition-slow: 420ms ease;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  font-size: var(--text-base);
  line-height: 1.65;
  color: var(--color-text);
  background-color: var(--color-bg);
  min-height: 100dvh;
}

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

ul, ol {
  list-style: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* ── Typography ─────────────────────────────────────────────── */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 600;
  line-height: 1.2;
  color: var(--color-text);
}

p {
  max-width: 68ch;
}

p + p {
  margin-top: var(--space-4);
}

strong {
  font-weight: 600;
}

a {
  color: var(--color-amber-light);
  text-decoration: none;
  transition: color var(--transition-fast);
}

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

/* ── Skip link (accessibility) ──────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--space-4);
  padding: var(--space-2) var(--space-4);
  background: var(--color-amber);
  color: #fff;
  font-size: var(--text-sm);
  border-radius: 0 0 6px 6px;
  z-index: 300;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 0;
}

/* ── Layout ─────────────────────────────────────────────────── */
.container {
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--space-6);
}

/* ── Site Footer ────────────────────────────────────────────── */
.site-footer {
  border-top: 1px solid var(--color-border);
  padding-block: var(--space-8);
}

.footer-inner {
  max-width: var(--max-width);
  margin-inline: auto;
  padding-inline: var(--space-6);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.footer-copy {
  font-size: var(--text-sm);
  color: var(--color-text-muted);
  max-width: none;
}

.footer-est {
  font-family: var(--font-heading);
  font-size: var(--text-sm);
  font-style: italic;
  color: var(--color-text-faint);
  max-width: none;
}

.footer-est-label {
  font-style: normal;
  font-size: var(--text-xs);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-right: var(--space-1);
  color: var(--color-text-faint);
}

/* ── Landing Page ───────────────────────────────────────────── */

/* Hero */
.landing-hero {
  text-align: center;
  padding: var(--space-20) var(--space-6) var(--space-16);
  max-width: var(--max-width);
  margin-inline: auto;
}

.hero-domain {
  font-family: var(--font-heading);
  font-size: clamp(var(--text-4xl), 6vw, var(--text-6xl));
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-text);
}

.hero-divider {
  width: 48px;
  height: 2px;
  background: var(--color-amber);
  border: none;
  border-radius: 2px;
  margin: var(--space-5) auto;
}

.hero-tagline {
  font-family: var(--font-heading);
  font-size: var(--text-lg);
  font-style: italic;
  font-weight: 400;
  color: var(--color-text-muted);
  line-height: 1.5;
  max-width: none;
  text-align: center;
}

.hero-tagline a {
  color: var(--color-text-muted);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--color-amber);
  transition: color var(--transition-fast);
}

.hero-tagline a:hover {
  color: var(--color-text);
}

/* Cards grid */
.cards-section {
  padding: 0 var(--space-6) var(--space-20);
  max-width: var(--max-width);
  margin-inline: auto;
}

.cards-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-5);
}

/* Row label between card groups */
.cards-row-label {
  font-size: var(--text-xs);
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-faint);
  padding-block: var(--space-2);
  grid-column: 1 / -1;
}

/*
 * Section divider variant — adds a ruled line above the label.
 * Used between the companies and personal rows.
 * Remove this modifier class from the label to restore the unruled look.
 */
.cards-row-label--divided {
  border-top: 1px solid var(--color-border);
  margin-top: var(--space-5);
}

/* ── Individual card ────────────────────────────────────────── */
.site-card {
  position: relative;
  border-radius: var(--card-radius);
  overflow: hidden;
  aspect-ratio: 16 / 9;
  background-color: var(--color-surface);
  border: 1px solid var(--color-border);
  display: block;
  text-decoration: none;
  transition: transform var(--transition-base),
              border-color var(--transition-base),
              box-shadow var(--transition-base);
}

.site-card:hover {
  transform: translateY(-3px) scale(1.01);
  border-color: var(--color-border-mid);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5),
              0 0 0 1px var(--color-amber-glow);
}

/* ── Background image + blur ────────────────────────────────── */
.card-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center center;
  transition: transform var(--transition-slow),
              filter var(--transition-slow);
}

.site-card:hover .card-bg {
  transform: scale(1.04);
}

/*
 * Company cards: blurred screenshot background.
 * The blur softens the screenshot so logos/text read cleanly
 * without the screenshot competing with the overlay text.
 */
.card-bg--blurred {
  filter: blur(2px) brightness(0.65) saturate(0.75);
  /* compensate for blur edge bleed */
  inset: -6px;
}

.site-card:hover .card-bg--blurred {
  filter: blur(1.5px) brightness(0.72) saturate(0.85);
}

/*
 * Personal cards: no blur — photos should read clearly.
 * Brightness pulled down a touch so white text is legible.
 */
.card-bg--photo {
  filter: brightness(0.75) saturate(0.9);
}

.site-card:hover .card-bg--photo {
  filter: brightness(0.82) saturate(1.0);
}

/* ── Gradient overlays ──────────────────────────────────────── */

/*
 * Company cards: gradient from bottom (where text sits after flip).
 * Top area stays relatively clear so logos show well.
 */
.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(8, 8, 8, 0.88) 0%,
    rgba(8, 8, 8, 0.50) 40%,
    rgba(8, 8, 8, 0.10) 100%
  );
}

/*
 * Personal cards: text is at the TOP, so gradient runs top-to-bottom.
 * Bottom stays clear so the photography/music image breathes.
 */
.card-overlay--personal {
  background: linear-gradient(
    to bottom,
    rgba(8, 8, 8, 0.82) 0%,
    rgba(8, 8, 8, 0.40) 40%,
    rgba(8, 8, 8, 0.05) 100%
  );
}

/* ── Card content layer ─────────────────────────────────────── */
.card-content {
  position: absolute;
  inset: 0;
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  /* Company cards: logo top, text bottom */
  justify-content: space-between;
}

/*
 * Personal cards: text at top, image shows at bottom.
 */
.card-content--top {
  justify-content: flex-start;
}

/* Shared text shadow for legibility over any background */
.card-label,
.card-sublabel,
.card-tag-row {
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.9),
               0 1px  4px rgba(0, 0, 0, 0.7);
}

/* Company logo */
.card-logo {
  height: 40px;
  width: auto;
  max-width: 52px;
  object-fit: contain;
  object-position: left center;
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.8));
  opacity: 0.95;
  flex-shrink: 0;
  align-self: flex-start;
}

/* Brede Logic SVG — natural navy + amber colours */
.card-logo--natural-dark {
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.95))
          drop-shadow(0 0px  4px rgba(0, 0, 0, 0.80));
}

/* Kalmeren mark — natural colours */
.card-logo--natural {
  filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.8));
}

/*
 * Hidden logo — keeps the flex spacer so card-meta stays at the bottom,
 * but renders nothing. Remove this class to restore the logo.
 */
.card-logo--hidden {
  visibility: hidden;
}

/* Card text */
.card-meta {
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
}

.card-label {
  font-family: var(--font-heading);
  font-size: var(--text-xl);
  font-weight: 600;
  color: #fff;
  line-height: 1.2;
}

.card-sublabel {
  font-size: var(--text-sm);
  font-weight: 300;
  color: rgba(255, 255, 255, 0.75);
  letter-spacing: 0.02em;
}

/* Amber dot + domain line on company cards */
.card-accent-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-amber-light);
  margin-right: var(--space-2);
  flex-shrink: 0;
  position: relative;
  top: -1px;
}

.card-tag-row {
  display: flex;
  align-items: center;
}

/* ── Utility ────────────────────────────────────────────────── */
.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;
}

/* ── Responsive ─────────────────────────────────────────────── */
@media (max-width: 640px) {
  .cards-grid {
    grid-template-columns: 1fr;
  }

  .site-card {
    aspect-ratio: 4 / 3;
  }

  .landing-hero {
    padding-top: var(--space-16);
    padding-bottom: var(--space-10);
  }
}

@media (max-width: 400px) {
  .hero-domain {
    font-size: var(--text-4xl);
  }
}

/* ── Print ──────────────────────────────────────────────────── */
@media print {
  .site-footer { display: none; }
}
