/* ============================================================
   HomeLogic · Edgar Maldonado · Contact Card
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Cormorant:wght@400;600;700&family=Inter:wght@300;400;500&display=swap');

:root {
  --gold:       #c8a84b;
  --gold-dim:   #6b5520;
  --bg:         #09090b;
  --page-bg:    #050506;
  --surface2:   #16161a;
  --border:     #222227;
  --text:       #ece8df;
  --muted:      #6a6760;
  --green-bg:   #0c180c;
  --green:      #4caf50;
  --green-bdr:  #1a321a;
  --save-bg:    #0e0e1a;
  --save-color: #8b9cf4;
  --save-bdr:   #1e2040;
  /* Social brand colors */
  --fb-color:   #1877f2;
  --fb-bg:      #0a1628;
  --fb-bdr:     #102040;
  --ig-color:   #e1306c;
  --ig-bg:      #1a0a10;
  --ig-bdr:     #3a1020;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; }

body {
  background: var(--page-bg);
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-weight: 300;
  overflow-x: hidden;
  background-image: radial-gradient(circle, #1a1a1f 1px, transparent 1px);
  background-size: 28px 28px;
}

/* ============================================================
   OUTER PAGE — Bootstrap-style container centering
   No forced height, no overflow issues
   ============================================================ */
.page-outer {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
}

/* Bootstrap-like container: natural width with auto margins */
.container-card {
  width: 100%;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================================
   CARD FRAME
   ============================================================ */
.card-frame {
  display: flex;
  width: 100%;
  /* Let height grow naturally from content — no fixed height forcing scroll */
  min-height: 580px;
  background: var(--bg);
  border-radius: 20px;
  overflow: hidden;
  border: 1px solid #1e1e23;
  box-shadow:
    0 0 0 1px rgba(200,168,75,0.07),
    0 24px 64px rgba(0,0,0,0.65),
    0 6px 20px rgba(0,0,0,0.4);
}

/* ── LEFT: Photo column ── */
.col-photo {
  width: 280px;
  flex-shrink: 0;
  position: relative;
  background: #060608;
  overflow: hidden;
  border-radius: 20px 0 0 20px;
}

.full-photo {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  image-rendering: -webkit-optimize-contrast;
  image-rendering: crisp-edges;
}

/* Right-edge fade */
.photo-fade-right {
  position: absolute;
  top: 0; bottom: 0; right: 0;
  width: 60px;
  background: linear-gradient(to right, transparent, var(--bg));
  pointer-events: none;
}

/* Gold accent line */
.col-photo::after {
  content: '';
  position: absolute;
  top: 8%;
  right: 0;
  width: 1.5px;
  height: 84%;
  background: linear-gradient(to bottom,
    transparent,
    var(--gold) 30%,
    var(--gold) 70%,
    transparent);
}

/* ── RIGHT: Info column ── */
.col-info {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 1.8rem 2.2rem 1.8rem 2rem;
  min-width: 0;
  background: var(--bg);
  border-radius: 0 20px 20px 0;
}

/* Pushes everything below the logo down by ~one button height */
.name-block {
  margin-top: 0;
}

/* ============================================================
   TOP BAR — logo top-right
   ============================================================ */
.top-bar {
  display: flex;
  justify-content: flex-end;
  align-items: flex-start;
  margin-bottom: 1.2rem;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.05s forwards;
}

.logo-img {
  width: auto;
  max-width: 160px;
  height: auto;
  display: block;
}

/* ============================================================
   NAME & IDENTITY
   ============================================================ */
.name-block {
  margin-bottom: 1rem;
  margin-top: 0;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.15s forwards;
}

.name {
  font-family: 'Cormorant', serif;
  font-size: 2.6rem;
  font-weight: 700;
  line-height: 1.0;
  letter-spacing: 0.01em;
  color: var(--text);
  margin-bottom: 0.4rem;
}

.title-line {
  font-size: 0.63rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 0.7rem;
}

.badge-row {
  display: flex;
  gap: 0.38rem;
  flex-wrap: wrap;
}

.badge {
  font-size: 0.55rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
  border-radius: 100px;
  padding: 0.2rem 0.65rem;
  background: rgba(200,168,75,0.05);
}

/* ============================================================
   GOLD RULE
   ============================================================ */
.gold-rule {
  width: 36px;
  height: 1.5px;
  background: var(--gold);
  margin-bottom: 1rem;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.22s forwards;
}

/* ============================================================
   ACTION BUTTONS
   ============================================================ */
.actions {
  display: flex;
  flex-direction: column;
  gap: 0.42rem;
  margin-bottom: 1.1rem;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.32s forwards;
}

.btn-action {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.62rem 0.85rem;
  border-radius: 10px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  font-family: 'Inter', sans-serif;
  transition: transform 0.16s ease, box-shadow 0.16s ease,
              background 0.16s ease, border-color 0.16s ease;
  position: relative;
  overflow: hidden;
}

.btn-action:hover  { transform: translateY(-1px); }
.btn-action:active { transform: scale(0.98); }

/* Gold / Call */
.btn-action.gold {
  background: linear-gradient(135deg, #b8942a 0%, #d4ae50 100%);
  color: #07050a;
}
.btn-action.gold:hover       { box-shadow: 0 6px 22px rgba(200,168,75,0.28); }
.btn-action.gold .btn-ico    { background: rgba(0,0,0,0.12); color: #07050a; }
.btn-action.gold .btn-title  { color: #07050a; font-weight: 600; }
.btn-action.gold .btn-detail { color: rgba(7,5,10,0.5); }
.btn-action.gold .btn-arrow  { color: rgba(7,5,10,0.28); }

/* WhatsApp */
.btn-action.green {
  background: var(--green-bg);
  border-color: var(--green-bdr);
}
.btn-action.green:hover       { background: #0f1e0f; border-color: #244224; }
.btn-action.green .btn-ico    { background: rgba(76,175,80,0.08); color: var(--green); }
.btn-action.green .btn-title  { color: var(--green); font-weight: 500; }
.btn-action.green .btn-detail { color: rgba(76,175,80,0.5); }
.btn-action.green .btn-arrow  { color: rgba(76,175,80,0.3); }

/* Ghost outline */
.btn-action.outline {
  background: var(--surface2);
  border-color: var(--border);
}
.btn-action.outline:hover       { border-color: var(--gold-dim); background: #1a1a20; }
.btn-action.outline .btn-ico    { background: rgba(255,255,255,0.04); color: var(--gold); }
.btn-action.outline .btn-title  { color: var(--text); font-weight: 400; }
.btn-action.outline .btn-detail { color: var(--muted); }
.btn-action.outline .btn-arrow  { color: var(--border); }

/* Save Contact */
.btn-action.save {
  background: var(--save-bg);
  border-color: var(--save-bdr);
}
.btn-action.save:hover       { border-color: #2e3460; background: #12122a; box-shadow: 0 6px 20px rgba(139,156,244,0.1); }
.btn-action.save .btn-ico    { background: rgba(139,156,244,0.1); color: var(--save-color); }
.btn-action.save .btn-title  { color: var(--save-color); font-weight: 500; }
.btn-action.save .btn-detail { color: rgba(139,156,244,0.5); }
.btn-action.save .btn-arrow  { color: var(--save-color); }

/* Shared inner parts */
.btn-ico {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  flex-shrink: 0;
}

.btn-body {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  text-align: left;
  min-width: 0;
}

.btn-title  { font-size: 0.75rem; letter-spacing: 0.03em; white-space: nowrap; }
.btn-detail { font-size: 0.61rem; letter-spacing: 0.02em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.btn-arrow  { font-size: 0.55rem; flex-shrink: 0; }

/* ============================================================
   SOCIAL — brand colors
   ============================================================ */
.social-block {
  display: flex;
  align-items: center;
  gap: 0.9rem;
  margin-top: auto;
  padding-top: 1rem;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.5s forwards;
}

.social-label {
  font-size: 0.55rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
}

.social-icons { display: flex; gap: 0.5rem; }

.social-ico {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.82rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

/* Facebook — blue */
.social-ico.fb {
  background: var(--fb-bg);
  border-color: var(--fb-bdr);
  color: var(--fb-color);
}
.social-ico.fb:hover {
  background: #0d1e38;
  border-color: #1877f2;
  box-shadow: 0 4px 14px rgba(24,119,242,0.25);
  transform: translateY(-2px);
}

/* Instagram — pink/red */
.social-ico.ig {
  background: var(--ig-bg);
  border-color: var(--ig-bdr);
  color: var(--ig-color);
}
.social-ico.ig:hover {
  background: #280a18;
  border-color: #e1306c;
  box-shadow: 0 4px 14px rgba(225,48,108,0.25);
  transform: translateY(-2px);
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer-copy {
  font-size: 0.54rem;
  letter-spacing: 0.1em;
  color: var(--muted);
  margin-top: 0.7rem;
  opacity: 0;
  animation: fadeUp 0.6s ease 0.6s forwards;
}

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

/* logo-inline only visible on mobile */
.logo-inline { display: none; }

/* ============================================================
   TABLET
   ============================================================ */
@media (max-width: 860px) {
  .col-photo { width: 240px; }
  .col-info  { padding: 1.5rem 1.6rem 1.5rem 1.4rem; }
  .logo-img  { max-width: 130px; }
  .name      { font-size: 2.1rem; }
}

/* ============================================================
   MOBILE — scrollable, photo visible, all content accessible
   ============================================================ */
@media (max-width: 600px) {

  /* Let the whole page scroll naturally */
  html, body {
    height: auto !important;
    overflow-x: hidden;
    overflow-y: auto !important;
  }

  .page-outer {
    padding: 0;
    height: auto;
    min-height: 100dvh;
    overflow: visible;
    align-items: flex-start;
  }

  .container-card {
    max-width: 100%;
    height: auto;
  }

  .card-frame {
    flex-direction: column;
    height: auto;
    min-height: 100dvh;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-top: none;
    overflow: visible;
  }

  /* Photo at top — 45% of screen */
  .col-photo {
    width: 100%;
    height: 45vh;
    flex-shrink: 0;
    border-radius: 0;
    overflow: hidden;
    position: relative;
    z-index: 0;
  }

  .full-photo {
    object-position: top center;
    height: 100%;
  }

  .col-photo::before {
    content: '';
    position: absolute;
    bottom: 0; left: 0; right: 0;
    height: 90px;
    background: linear-gradient(to bottom, transparent, var(--bg));
    pointer-events: none;
  }

  .col-photo::after { display: none; }
  .photo-fade-right { display: none; }

  /* Info panel slides up 50px over the photo */
  .col-info {
    position: relative;
    z-index: 1;
    margin-top: -50px;
    padding: 1.2rem 1.1rem 2rem;
    border-radius: 20px 20px 0 0;
    border-top: 1px solid #1e1e23;
    background: var(--bg);
    display: flex;
    flex-direction: column;
    overflow: visible;
    flex: 1;
  }

  /* Hide top-bar — logo goes next to name */
  .top-bar { display: none; }

  /* Name row: text left, logo right */
  .name-block {
    display: flex;
    flex-direction: row;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.8rem;
    margin-top: 0 !important;
    margin-bottom: 0.6rem;
  }

  .name-block .name-text { flex: 1; min-width: 0; }

  .name-block .logo-inline {
    display: block;
    max-width: 90px;
    height: auto;
    flex-shrink: 0;
    margin-top: 0.3rem;
  }

  .name       { font-size: 1.8rem; }
  .title-line { margin-bottom: 0.4rem; }
  .badge-row  { margin-bottom: 0; }
  .gold-rule  { margin-bottom: 0.6rem; }
  .actions    { gap: 0.4rem; margin-bottom: 0.8rem; }
  .btn-action { padding: 0.6rem 0.85rem; }
  .btn-detail { display: block; }

  .social-block { padding-top: 0.5rem; margin-top: 0; margin-bottom: 0; }
  .footer-copy  { margin-top: 0.8rem; padding-bottom: 1.5rem; }
}
