/* ═══════════════════════════════════════════════════
   mcreef.de  —  Landing Page Styles
   Color scheme: Teal/Cyan — light in both modes
   ═══════════════════════════════════════════════════ */

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

/* ─── DESIGN TOKENS ─────────────────────────────── */
:root {
  /* Backgrounds */
  --bg:           #F0F4F8;
  --bg2:          #E4EDF5;

  /* Glass */
  --glass-top:    rgba(255, 255, 255, 0.78);
  --glass-bot:    rgba(255, 255, 255, 0.55);
  --glass-border: rgba(255, 255, 255, 0.90);
  --glass-inner:  rgba(255, 255, 255, 0.55);
  --glass-sheen:  rgba(255, 255, 255, 0.26);

  /* Shadows */
  --shadow-sm:    0 2px 6px  rgba(0,0,0,0.05),
                  0 8px 24px rgba(0,0,0,0.07),
                  0 32px 56px rgba(0,0,0,0.05);
  --shadow-lg:    0 2px 6px  rgba(0,0,0,0.07),
                  0 12px 32px rgba(0,0,0,0.10),
                  0 40px 72px rgba(0,0,0,0.09);

  /* Accent — Teal */
  --accent:       #0891B2;   /* cyan-600  */
  --accent2:      #0E7490;   /* cyan-700  */
  --accent-light: #67E8F9;   /* cyan-300  */
  --accent-rgb:   8, 145, 178;
  --accent-glow:  rgba(8, 145, 178, 0.20);
  --accent-muted: rgba(8, 145, 178, 0.10);

  /* Text */
  --text:         #1A2332;
  --text2:        #5A6A7A;
  --text3:        #A0B0C0;

  /* Blobs */
  --b1: rgba(14, 165, 233, 0.12);   /* sky    */
  --b2: rgba(6,  182, 212, 0.09);   /* cyan   */
  --b3: rgba(20, 184, 166, 0.11);   /* teal   */
  --b4: rgba(186,230,255, 0.28);    /* pale sky */

  --blur: 52px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg:           #09111A;
    --bg2:          #0D1822;

    --glass-top:    rgba(255, 255, 255, 0.08);
    --glass-bot:    rgba(255, 255, 255, 0.04);
    --glass-border: rgba(255, 255, 255, 0.12);
    --glass-inner:  rgba(255, 255, 255, 0.07);
    --glass-sheen:  rgba(255, 255, 255, 0.08);

    --shadow-sm:    0 2px 6px  rgba(0,0,0,0.40),
                    0 8px 24px rgba(0,0,0,0.55),
                    0 32px 56px rgba(0,0,0,0.50);
    --shadow-lg:    0 2px 6px  rgba(0,0,0,0.50),
                    0 12px 32px rgba(0,0,0,0.65),
                    0 40px 72px rgba(0,0,0,0.60);

    /* Accent — lighter teal for dark bg */
    --accent:       #22D3EE;   /* cyan-400  */
    --accent2:      #06B6D4;   /* cyan-500  */
    --accent-light: #A5F3FC;   /* cyan-200  */
    --accent-rgb:   34, 211, 238;
    --accent-glow:  rgba(34, 211, 238, 0.22);
    --accent-muted: rgba(34, 211, 238, 0.10);

    --text:         #E8F0F8;
    --text2:        #8A9BAC;
    --text3:        #445566;

    --b1: rgba(6,  182, 212, 0.18);
    --b2: rgba(14, 165, 233, 0.12);
    --b3: rgba(20, 184, 166, 0.14);
    --b4: rgba(8,  51,  68,  0.30);
  }
}

/* ─── BASE ──────────────────────────────────────── */
html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'SF Pro Display',
               'Segoe UI', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 52px 16px 72px;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ─── ANIMATED BLOBS ────────────────────────────── */
.canvas {
  position: fixed; inset: 0;
  z-index: 0; pointer-events: none; overflow: hidden;
}

.blob {
  position: absolute; border-radius: 50%;
  filter: blur(100px); will-change: transform;
}
.b1 { width:640px; height:640px; background:var(--b1); top:-160px; left:-120px; animation:d1 24s ease-in-out infinite; }
.b2 { width:480px; height:480px; background:var(--b2); top:30%; right:-80px;   animation:d2 30s ease-in-out infinite; }
.b3 { width:420px; height:420px; background:var(--b3); bottom:5%; left:5%;     animation:d3 22s ease-in-out infinite; }
.b4 { width:360px; height:360px; background:var(--b4); bottom:-60px; right:15%;animation:d4 26s ease-in-out infinite; }

@keyframes d1 {
  0%,100% { transform: translate(0,0)      scale(1);    }
  33%      { transform: translate(80px,100px) scale(1.12); }
  66%      { transform: translate(-50px,50px) scale(0.93); }
}
@keyframes d2 {
  0%,100% { transform: translate(0,0)          scale(1);    }
  40%      { transform: translate(-100px,-70px) scale(1.09); }
  70%      { transform: translate(40px,-40px)   scale(0.91); }
}
@keyframes d3 {
  0%,100% { transform: translate(0,0)      scale(1);    }
  50%      { transform: translate(60px,-80px) scale(1.14); }
}
@keyframes d4 {
  0%,100% { transform: translate(0,0)         scale(1);    }
  35%      { transform: translate(-50px,-60px) scale(1.06); }
  65%      { transform: translate(38px,-25px)  scale(0.96); }
}

/* ─── GLASS BASE ────────────────────────────────── */
.glass {
  position: relative; overflow: hidden;
  background: linear-gradient(160deg, var(--glass-top) 0%, var(--glass-bot) 100%);
  backdrop-filter: blur(var(--blur)) saturate(220%) brightness(1.03);
  -webkit-backdrop-filter: blur(var(--blur)) saturate(220%) brightness(1.03);
  border: 1px solid var(--glass-border);
  box-shadow:
    inset 0  1px 0 var(--glass-inner),
    inset 0 -1px 0 rgba(0,0,0,0.03),
    var(--shadow-sm);
  border-radius: 24px;
  transition:
    background   0.4s ease,
    box-shadow   0.4s ease,
    transform    0.35s cubic-bezier(0.34,1.56,0.64,1),
    border-color 0.3s ease;
}

/* Specular sheen */
.glass::before {
  content: '';
  position: absolute; top:0; left:0; right:0; height:52%; z-index:0;
  background: linear-gradient(180deg,
    var(--glass-sheen) 0%,
    rgba(255,255,255,0.04) 55%,
    transparent 100%
  );
  border-radius: inherit; pointer-events: none;
}

/* Edge refraction highlight */
.glass::after {
  content: '';
  position: absolute; inset:0; z-index:0;
  border-radius: inherit;
  border: 1px solid rgba(255,255,255,0.18);
  pointer-events: none;
}

/* Children above pseudo-elements */
.glass > * { position: relative; z-index: 1; }

.glass:hover {
  box-shadow:
    inset 0  1px 0 var(--glass-inner),
    inset 0 -1px 0 rgba(0,0,0,0.03),
    var(--shadow-lg);
}

/* ─── LAYOUT ────────────────────────────────────── */
.wrap {
  position: relative; z-index: 1;
  width: 100%; max-width: 420px;
  display: flex; flex-direction: column;
  align-items: stretch; gap: 12px;
}

/* ─── PROFILE CARD ──────────────────────────────── */
.profile-card {
  padding: 36px 24px 28px;
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
}

/* ── Photo ── */
.photo-wrap {
  position: relative; width: 112px; height: 112px;
  margin-bottom: 20px;
}

.photo-inner {
  width: 100%; height: 100%;
  border-radius: 50%; overflow: hidden;
  /* Clean static border — no spinning ring */
  box-shadow:
    0 0 0 3px rgba(var(--accent-rgb), 0.30),
    0 0 0 5px rgba(var(--accent-rgb), 0.10),
    0 8px 24px rgba(0,0,0,0.15);
}

.photo-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  font-size: 30px; font-weight: 700; color: #fff;
  letter-spacing: -1px;
}

.photo-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; border-radius: 50%;
  opacity: 0;
  transition: opacity 0.4s ease;
}
.photo-img.loaded { opacity: 1; }

/* ── Name & Bio ── */
.profile-name {
  font-size: 22px; font-weight: 700;
  letter-spacing: -0.4px; line-height: 1.2;
  color: var(--text); margin-bottom: 5px;
}
.profile-bio {
  font-size: 13.5px; color: var(--text2);
  line-height: 1.55; margin-bottom: 24px;
}

/* ─── FOLLOW LABEL ──────────────────────────────── */
.follow-label {
  font-size: 10px; font-weight: 600;
  letter-spacing: 2.5px; text-transform: uppercase;
  color: var(--text3); margin-bottom: 12px;
}

/* ─── SOCIAL ROW ────────────────────────────────── */
.social-row {
  display: flex; gap: 10px; justify-content: center;
}

.social-btn {
  display: flex; flex-direction: column;
  align-items: center; gap: 5px;
  width: 60px; padding: 11px 0 9px;
  border-radius: 18px;
  background: linear-gradient(160deg, var(--glass-top), var(--glass-bot));
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid var(--glass-border);
  box-shadow: inset 0 1px 0 var(--glass-inner), var(--shadow-sm);
  color: var(--text);
  text-decoration: none;
  overflow: hidden; position: relative;
  transition: all 0.30s cubic-bezier(0.34,1.56,0.64,1);
}

.social-btn::before {
  content: '';
  position: absolute; inset: 0;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  opacity: 0; transition: opacity 0.25s ease;
}

.social-btn:hover {
  transform: translateY(-5px) scale(1.10);
  border-color: var(--accent);
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,0.35),
    var(--shadow-lg),
    0 0 28px var(--accent-glow);
}
.social-btn:hover::before { opacity: 1; }
.social-btn:hover .s-icon { fill: #fff; }
.social-btn:hover .s-lbl  { color: #fff; }

.s-icon {
  width: 22px; height: 22px;
  fill: var(--text);
  position: relative; z-index: 1;
  transition: fill 0.25s ease;
}
.s-lbl {
  font-size: 9px; font-weight: 600;
  letter-spacing: 0.3px; color: var(--text3);
  position: relative; z-index: 1;
  transition: color 0.25s ease;
}

/* ─── LINK CARDS ────────────────────────────────── */
.link-card {
  padding: 14px 16px;
  display: flex; align-items: center; gap: 13px;
  text-decoration: none; color: var(--text);
}

.link-card:hover {
  transform: translateY(-2px) scale(1.008);
  box-shadow: inset 0 1px 0 var(--glass-inner), var(--shadow-lg);
}
.link-card:hover .lc-title   { color: var(--accent); }
.link-card:hover .lc-chevron { color: var(--accent); transform: translateX(3px); }

.lc-icon {
  width: 42px; height: 42px; border-radius: 12px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 14px var(--accent-glow);
}
.lc-icon svg { width: 20px; height: 20px; fill: #fff; }

.lc-text { flex: 1; min-width: 0; }
.lc-title {
  font-size: 14px; font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
  transition: color 0.2s;
}
.lc-sub {
  font-size: 11.5px; color: var(--text2); margin-top: 2px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.lc-chevron {
  font-size: 20px; color: var(--text3); flex-shrink: 0;
  transition: color 0.2s, transform 0.2s;
}

/* ─── FOOTER ────────────────────────────────────── */
footer {
  display: flex; align-items: center; justify-content: center;
  gap: 10px; font-size: 11.5px; color: var(--text3);
  margin-top: 6px; flex-wrap: wrap;
}
footer a { color: var(--text2); text-decoration: none; transition: color 0.2s; }
footer a:hover { color: var(--accent); }
.dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text3); }

/* ─── MODAL OVERLAY ─────────────────────────────── */
.overlay {
  position: fixed; inset: 0;
  /* No backdrop-filter here — iOS Safari blocks touch events on full-screen
     backdrop-filter elements. The blur lives on .sheet only. */
  background: rgba(0,0,0,0.38);
  z-index: 300;
  opacity: 0; pointer-events: none;
  transition: opacity 0.30s ease;
  display: flex; align-items: flex-end; justify-content: center;
  /* Prevent tap-through on iOS */
  -webkit-tap-highlight-color: transparent;
}
.overlay.open { opacity: 1; pointer-events: all; }

/* ─── SHEET ─────────────────────────────────────── */
.sheet {
  position: relative;
  width: 100%; max-width: 500px; max-height: 88vh;
  /* overflow-y only — never overflow:hidden + overflow-y:auto together */
  overflow-y: auto;
  -webkit-overflow-scrolling: touch; /* smooth scroll on iOS */
  background: linear-gradient(160deg, var(--glass-top), var(--glass-bot));
  backdrop-filter: blur(64px) saturate(240%) brightness(1.04);
  -webkit-backdrop-filter: blur(64px) saturate(240%) brightness(1.04);
  border: 1px solid var(--glass-border);
  border-bottom: none;
  border-radius: 28px 28px 0 0;
  box-shadow:
    inset 0 1px 0 var(--glass-inner),
    0 -8px 40px rgba(0,0,0,0.14),
    0 -2px 12px rgba(0,0,0,0.08);
  padding: 0 24px 52px;
  transform: translateY(100%);
  transition: transform 0.42s cubic-bezier(0.32,0.72,0,1);
}
.overlay.open .sheet { transform: translateY(0); }

.sheet::before {
  content: '';
  position: absolute; top:0; left:0; right:0; height:35%; z-index:0;
  background: linear-gradient(180deg, var(--glass-sheen) 0%, transparent 100%);
  border-radius: inherit; pointer-events: none;
}
.sheet > * { position: relative; z-index: 1; }

.handle {
  width: 44px; height: 5px; border-radius: 3px;
  background: var(--text3); opacity: 0.45;
  margin: 14px auto 20px;
}

.sheet-close {
  position: absolute; top: 16px; right: 20px; z-index: 2;
  width: 30px; height: 30px; border-radius: 50%;
  background: var(--accent-muted); border: 1px solid var(--glass-border);
  color: var(--text2); font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: all 0.2s; font-family: inherit;
}
.sheet-close:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ─── SHEET CONTENT ─────────────────────────────── */
.sheet h2 {
  font-size: 20px; font-weight: 700;
  color: var(--text); margin-bottom: 20px;
}
.sheet h3 {
  font-size: 10.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1.2px;
  color: var(--accent); margin: 20px 0 7px;
}
.sheet p,
.sheet address {
  font-size: 14px; line-height: 1.75;
  color: var(--text2); font-style: normal;
}
.divider { height: 1px; background: var(--glass-border); margin: 4px 0; }

.reveal {
  display: inline-flex; align-items: center; gap: 7px;
  font-size: 14px; color: var(--accent);
  background: none; border: none; padding: 2px 0;
  cursor: pointer; font-family: inherit;
  transition: opacity 0.2s; text-decoration: none;
}
.reveal:hover { opacity: 0.70; }
.reveal svg { width:14px; height:14px; fill:currentColor; flex-shrink:0; }

/* ─── SCROLLBAR ─────────────────────────────────── */
.sheet::-webkit-scrollbar { width: 3px; }
.sheet::-webkit-scrollbar-track { background: transparent; }
.sheet::-webkit-scrollbar-thumb { background: var(--text3); border-radius: 2px; }

/* ─── ENTRANCE ANIMATION ────────────────────────── */
@keyframes up {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0);    }
}
.wrap > * { animation: up 0.55s cubic-bezier(0.22,1,0.36,1) both; }
.wrap > *:nth-child(1) { animation-delay: .04s; }
.wrap > *:nth-child(2) { animation-delay: .11s; }
.wrap > *:nth-child(3) { animation-delay: .18s; }
.wrap > *:nth-child(4) { animation-delay: .25s; }
.wrap > *:nth-child(5) { animation-delay: .31s; }
.wrap > *:nth-child(6) { animation-delay: .37s; }

/* ─── RESPONSIVE ────────────────────────────────── */
@media (max-width: 440px) {
  body            { padding: 28px 10px 56px; }
  .profile-card   { padding: 28px 18px 24px; }
  .social-btn     { width: 54px; }
}
