/* ═══════════════════════════════════════════
   Hamza Saphar — AAA Digital Business Card
   Design A: Executive Dark
   ═══════════════════════════════════════════ */

:root {
  --green: #008540;
  --green-light: #00a950;
  --green-wa: #25D366;
  --dark: #0e0e0e;
  --dark-card: #161616;
  --surface: #1c1c1c;
  --text: #f5f5f5;
  --text-muted: #9a9a9a;
  --radius: 16px;
  --max-w: 430px;
}

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

html {
  background: #000;
  scroll-behavior: smooth;
}

body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: var(--dark);
  color: var(--text);
  min-height: 100dvh;
  display: flex;
  justify-content: center;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

/* ─── CARD CONTAINER ─── */
.card {
  width: 100%;
  max-width: var(--max-w);
  min-height: 100dvh;
  position: relative;
  padding-bottom: 90px;
}

/* ═══════ HERO ═══════ */
.hero {
  position: relative;
  width: 100%;
  aspect-ratio: 9 / 11;
  overflow: hidden;
  background: #111;
}

.hero-photo-wrap {
  position: absolute;
  inset: 0;
  overflow: hidden;
}

.hero-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 15%;
  display: block;
  transform: scale(1);
  transition: transform .08s linear;
  will-change: transform;
}

.hero-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(14,14,14,0) 25%,
    rgba(14,14,14,.3) 50%,
    rgba(14,14,14,.85) 78%,
    var(--dark) 100%
  );
  pointer-events: none;
}

.hero-hh {
  position: absolute;
  bottom: 105px;
  left: 24px;
  width: 64px;
  height: 64px;
  border-radius: 14px;
  border: 2px solid rgba(255,255,255,.12);
  background: rgba(30,30,30,.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 10px;
  z-index: 2;
}

.hero-hh img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.hero-info {
  position: absolute;
  bottom: 20px;
  left: 24px;
  right: 24px;
  z-index: 2;
}

.hero-title-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--green-light);
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-title-label::before {
  content: '';
  width: 20px;
  height: 1px;
  background: var(--green-light);
}

.hero-name {
  font-size: 32px;
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -.5px;
  margin-bottom: 4px;
}

.hero-company {
  font-size: 14px;
  color: var(--text-muted);
  font-weight: 300;
}

/* ═══════ QUICK ACTIONS ═══════ */
.actions {
  display: flex;
  gap: 10px;
  padding: 20px 24px;
}

.action-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 10px;
  border-radius: 12px;
  background: var(--green);
  color: #fff;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  transition: transform .12s ease, background .12s ease;
  -webkit-tap-highlight-color: transparent;
}

.action-btn:active {
  transform: scale(.96);
  background: var(--green-light);
}

.action-btn--wa {
  background: var(--green-wa);
}

.action-btn--wa:active {
  background: #1ebe5d;
}

.action-btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

/* ═══════ COMPANY (Full AAA Logo) ═══════ */
.company {
  margin: 8px 24px 0;
  border-radius: var(--radius);
  overflow: hidden;
  position: relative;
  display: block;
  text-decoration: none;
  color: var(--text);
  -webkit-tap-highlight-color: transparent;
}

.company-logo-full {
  width: 100%;
  display: block;
  border-radius: var(--radius);
  background: #fff;
  transform: scale(1);
  transition: transform .1s linear;
  will-change: transform;
}

.company-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px 20px;
  background: linear-gradient(to top, rgba(0,0,0,.7) 0%, transparent 100%);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-radius: 0 0 var(--radius) var(--radius);
}

.company-tagline {
  font-size: 13px;
  font-weight: 500;
  color: #fff;
}

.company-arrow-circle {
  width: 32px;
  height: 32px;
  color: rgba(255,255,255,.7);
}

.company-arrow {
  margin-left: auto;
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ═══════ SECTION LABEL ═══════ */
.section-label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 28px 24px 12px;
}

/* ═══════ CONTACT LIST ═══════ */
.contact-list {
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--surface);
  text-decoration: none;
  color: var(--text);
  transition: background .12s ease;
  -webkit-tap-highlight-color: transparent;
}

.ci-first { border-radius: var(--radius) var(--radius) 0 0; }
.ci-last { border-radius: 0 0 var(--radius) var(--radius); }

.contact-item:active {
  background: #252525;
}

.contact-item:active .contact-icon {
  background: var(--green);
}

.contact-item:active .contact-icon svg {
  color: #fff;
}

.contact-item:active .contact-value {
  color: var(--green-light);
}

.contact-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: rgba(0, 133, 64, .12);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.contact-icon svg {
  width: 16px;
  height: 16px;
  color: var(--green-light);
}

.contact-info {
  flex: 1;
  min-width: 0;
}

.contact-label {
  font-size: 10px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 2px;
}

.contact-value {
  font-size: 14px;
  font-weight: 500;
}

/* ═══════ SOCIAL ═══════ */
.social-row {
  display: flex;
  justify-content: center;
  gap: 14px;
  padding: 0 24px;
}

.social-link {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  background: var(--surface);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  text-decoration: none;
  transition: transform .12s ease, background .12s ease, color .12s ease;
  -webkit-tap-highlight-color: transparent;
}

.social-link:active {
  transform: scale(.92);
  background: var(--green);
  color: #fff;
  color: var(--text);
}

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

/* ═══════ PERSONAL LINK ═══════ */
.personal-link {
  margin: 14px 24px 0;
  padding: 16px 20px;
  background: var(--surface);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--text);
  transition: transform .12s ease, background .12s ease;
  -webkit-tap-highlight-color: transparent;
}

.personal-link:active {
  transform: scale(.98);
  background: #222;
  border-color: var(--green);
}

.personal-link-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  overflow: hidden;
  flex-shrink: 0;
}

.personal-link-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.personal-link-text h4 {
  font-size: 14px;
  font-weight: 500;
}

.personal-link-text p {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 300;
  margin-top: 1px;
}

/* ═══════ FOOTER ═══════ */
.footer {
  text-align: center;
  padding: 32px 24px 24px;
  font-size: 11px;
  color: #444;
}

/* ═══════ STICKY BOTTOM BAR ═══════ */
.bottom-bar {
  position: fixed;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  max-width: var(--max-w);
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  padding-bottom: max(12px, env(safe-area-inset-bottom));
  background: rgba(14, 14, 14, .88);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-top: 1px solid rgba(255, 255, 255, .06);
  z-index: 50;
}

.bar-btn {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 13px 8px;
  border-radius: 10px;
  border: none;
  font-family: inherit;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: transform .12s ease;
  -webkit-tap-highlight-color: transparent;
}

.bar-btn:active {
  transform: scale(.96);
}

.bar-btn svg {
  width: 16px;
  height: 16px;
}

.bar-btn--qr {
  background: var(--surface);
  color: var(--text-muted);
  flex: 0 0 auto;
  padding: 13px 14px;
}

.bar-btn--save {
  background: var(--green);
  color: #fff;
}

.bar-btn--install {
  background: var(--surface);
  color: var(--text);
  border: 1px solid rgba(255, 255, 255, .08);
}

/* ═══════ QR MODAL ═══════ */
.qr-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(0, 0, 0, .85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.qr-modal.active {
  display: flex;
}

.qr-box {
  background: #1a1a1a;
  border: 1px solid rgba(255, 255, 255, .08);
  border-radius: 28px;
  padding: 36px 28px 32px;
  text-align: center;
  max-width: 340px;
  width: 100%;
  position: relative;
  box-shadow: 0 0 60px rgba(0, 133, 64, .08);
}

.qr-close-x {
  position: absolute;
  top: 16px;
  right: 20px;
  background: none;
  border: none;
  color: #666;
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
  padding: 4px;
}

.qr-icon {
  width: 56px;
  height: 56px;
  border-radius: 14px;
  background: rgba(0, 133, 64, .15);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.qr-icon svg {
  width: 28px;
  height: 28px;
  color: #00a950;
}

.qr-title {
  font-size: 22px;
  font-weight: 700;
  color: #f5f5f5;
  margin-bottom: 8px;
}

.qr-desc {
  font-size: 13px;
  color: #888;
  line-height: 1.5;
  margin-bottom: 24px;
}

.qr-img {
  width: 220px;
  height: 220px;
  border-radius: 16px;
  margin: 0 auto;
  display: block;
  background: #fff;
}

.qr-url {
  margin-top: 20px;
  font-weight: 600;
  color: #00a950;
  font-size: 13px;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.qr-company {
  margin-top: 4px;
  font-size: 12px;
  color: #777;
}

/* ═══════ SCROLL ANIMATIONS ═══════ */

/* Fade-up on scroll reveal */
[data-scroll="fade"] {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .5s ease, transform .5s ease;
}

[data-scroll="fade"].scroll-visible {
  opacity: 1;
  transform: translateY(0);
}

/* Zoom-in on scroll reveal */
[data-scroll="zoom"] {
  opacity: 0;
  transform: scale(.92);
  transition: opacity .5s ease, transform .6s cubic-bezier(.22, 1, .36, 1);
}

[data-scroll="zoom"].scroll-visible {
  opacity: 1;
  transform: scale(1);
}

/* Parallax-style float for hero elements when scrolling */
.hero-hh {
  transition: transform .3s ease;
}

.hero.scrolled .hero-hh {
  transform: translateY(-4px) scale(1.02);
}

/* ═══════ DESKTOP / LARGE SCREENS ═══════ */
@media (min-width: 480px) {
  body {
    padding: 24px 0;
    align-items: flex-start;
  }

  .card {
    border-radius: 24px;
    overflow: hidden;
    min-height: auto;
    box-shadow: 0 8px 40px rgba(0,0,0,.4);
  }

  .bottom-bar {
    border-radius: 0 0 24px 24px;
  }
}
