/* ============================================================
   Milena Arzumanyan — digital business card
   World: cardiac monitor / EKG readout, rendered with restraint.
   Committed color: deep ink-teal field + one coral vital accent.
   Type: IBM Plex Sans (voice) + IBM Plex Mono (readouts: dates,
   numbers, phone, status line) — measurement typeface used for
   actual measurement, not costume.
   ============================================================ */

@font-face {
  font-family: "Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/plex-sans-400.woff2") format("woff2");
}
@font-face {
  font-family: "Plex Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/plex-sans-500.woff2") format("woff2");
}
@font-face {
  font-family: "Plex Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/plex-sans-600.woff2") format("woff2");
}
@font-face {
  font-family: "Plex Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("../fonts/plex-sans-700.woff2") format("woff2");
}
@font-face {
  font-family: "Plex Mono";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("../fonts/plex-mono-400.woff2") format("woff2");
}
@font-face {
  font-family: "Plex Mono";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("../fonts/plex-mono-500.woff2") format("woff2");
}

:root {
  --ink: #0a2f30;
  --ink-2: #0e3f40;
  --ink-soft: #d7ece9;
  --paper: #f4f7f6;
  --panel: #ffffff;
  --line: #d9e3e1;
  --text: #12312f;
  --text-dim: #4d6b67;
  --accent: #e8543f;
  --accent-ink: #b53c2b;
  --accent-soft: #fbe3de;
  --radius: 7px;
  --measure: 62ch;
  --gap-section: clamp(2.75rem, 6vw, 4.5rem);
}

* {
  box-sizing: border-box;
}

::selection {
  background: var(--accent);
  color: #fff;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: "Plex Sans", -apple-system, "Segoe UI", Roboto, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  scrollbar-color: var(--ink-2) var(--paper);
}

::-webkit-scrollbar {
  width: 12px;
}

::-webkit-scrollbar-track {
  background: var(--paper);
}

::-webkit-scrollbar-thumb {
  background: var(--ink-soft);
  border-radius: 8px;
  border: 3px solid var(--paper);
}

::-webkit-scrollbar-thumb:hover {
  background: var(--ink-2);
}

a {
  color: inherit;
}

/* focus ring, tuned to the palette rather than left as browser default */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

button {
  font: inherit;
  color: inherit;
}

.card {
  max-width: 640px;
  margin: 0 auto;
  background: var(--paper);
}

/* ---------------- Hero ---------------- */

.hero {
  background: linear-gradient(175deg, var(--ink) 0%, var(--ink-2) 100%);
  color: #eef6f5;
  padding: 2rem 1.5rem clamp(2.25rem, 6vw, 3rem);
  position: relative;
  overflow: hidden;
}

.hero-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.badge-photo {
  width: 56px;
  height: 56px;
  flex: none;
  object-fit: cover;
  border-radius: 9px;
  border: 2px solid rgba(238, 246, 245, 0.22);
  box-shadow: 0 10px 20px -10px rgba(0, 0, 0, 0.6);
}

.status-line {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-family: "Plex Mono", ui-monospace, monospace;
  font-size: 0.72rem;
  line-height: 1.5;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: #a9c9c5;
  padding-top: 0.3rem;
}

.status-dot {
  width: 7px;
  height: 7px;
  margin-top: 0.45em;
  border-radius: 50%;
  background: #34d399;
  box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.55);
  animation: pulse-dot 2.4s ease-out infinite;
  flex: none;
}

@keyframes pulse-dot {
  0% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0.55);
  }
  70% {
    box-shadow: 0 0 0 8px rgba(52, 211, 153, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(52, 211, 153, 0);
  }
}

.ekg-wrap {
  position: relative;
  margin: 0.9rem 0 0.6rem;
}

.ekg {
  display: block;
  width: 100%;
  height: 56px;
}

.ekg-heart {
  position: absolute;
  left: 100%;
  top: 50%;
  width: 9px;
  height: 9px;
  color: var(--accent);
  opacity: 0;
  transform: translate(-50%, -50%);
  transform-origin: center;
  animation:
    heart-arrive 0.5s ease-out 2.2s forwards,
    heartbeat 1.15s ease-in-out 2.2s infinite;
}

@keyframes heart-arrive {
  to {
    opacity: 1;
  }
}

@keyframes heartbeat {
  0%,
  100% {
    transform: translate(-50%, -50%) scale(1);
  }
  12% {
    transform: translate(-50%, -50%) scale(1.22);
  }
  24% {
    transform: translate(-50%, -50%) scale(1);
  }
  36% {
    transform: translate(-50%, -50%) scale(1.12);
  }
  48% {
    transform: translate(-50%, -50%) scale(1);
  }
}

.ekg path {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2.25;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 2700;
  stroke-dashoffset: 2700;
  animation: draw-ekg 2.2s cubic-bezier(0.16, 0.85, 0.2, 1) forwards;
}

@keyframes draw-ekg {
  to {
    stroke-dashoffset: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ekg path {
    animation: none;
    stroke-dashoffset: 0;
  }
  .ekg-heart {
    animation: none;
    opacity: 1;
  }
  .status-dot {
    animation: none;
  }
}

.name-row {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.name-mark {
  width: 56px;
  height: 56px;
  flex: none;
}

.hero h1 {
  margin: 0;
  font-size: clamp(1.9rem, 8vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.08;
}

.headline {
  margin: 0.5rem 0 0;
  font-size: 1.02rem;
  font-weight: 500;
  color: #cfe6e3;
}

.headline strong {
  color: #fff;
  font-weight: 600;
}

.credential {
  margin: 0.35rem 0 0;
  font-size: 0.86rem;
  font-weight: 500;
  color: #a9c9c5;
}

.hero-meta {
  margin: 0.9rem 0 0;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem 0.7rem;
  font-family: "Plex Mono", ui-monospace, monospace;
  font-size: 0.78rem;
  letter-spacing: 0.02em;
  color: #a9c9c5;
}

.hero-meta .sep {
  color: #3f6360;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-top: 1.5rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.05rem;
  border-radius: var(--radius);
  font-size: 0.92rem;
  font-weight: 600;
  text-decoration: none;
  border: 1.5px solid transparent;
  cursor: pointer;
  line-height: 1;
}

.btn svg {
  width: 16px;
  height: 16px;
  flex: none;
}

.btn-primary {
  background: var(--accent-ink);
  color: #fff;
}

.btn-primary:hover {
  background: #9c3420;
}

.hero .btn-outline {
  background: transparent;
  border-color: #3f6360;
  color: #eef6f5;
}

.hero .btn-outline:hover {
  border-color: #6c928d;
  background: rgba(255, 255, 255, 0.04);
}

/* ---------------- Sections ---------------- */

.section {
  padding: var(--gap-section) 1.5rem 0;
}

.section:last-of-type {
  padding-bottom: var(--gap-section);
}

.section h2 {
  margin: 0 0 1.1rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent-ink);
}

.section > p {
  margin: 0;
  max-width: var(--measure);
  color: var(--text);
  font-size: 1rem;
}

/* ---------------- Rail (shared by remote-work / experience / education) ---------------- */

.rail {
  list-style: none;
  margin: 0;
  padding: 0 0 0 1.9rem;
  position: relative;
  border-left: 2px solid var(--line);
}

.rail li {
  position: relative;
  padding-bottom: 1.5rem;
}

.rail li:last-child {
  padding-bottom: 0;
}

.rail li::before {
  content: "";
  position: absolute;
  left: calc(-1.9rem - 5px);
  top: 0.3rem;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--paper);
  border: 2px solid var(--accent);
}

.rail-icon {
  position: absolute;
  left: calc(-1.9rem - 10px);
  top: -1px;
  width: 18px;
  height: 18px;
  color: var(--accent-ink);
  background: var(--paper);
}

.rail-icon svg {
  width: 100%;
  height: 100%;
}

.rail.has-icons li::before {
  display: none;
}

.rail-title {
  font-weight: 600;
  font-size: 0.98rem;
  color: var(--text);
}

.rail-sub {
  margin-top: 0.15rem;
  font-size: 0.88rem;
  color: var(--text-dim);
}

.rail-date {
  margin-top: 0.3rem;
  font-family: "Plex Mono", ui-monospace, monospace;
  font-size: 0.76rem;
  letter-spacing: 0.02em;
  color: var(--text-dim);
}

/* ---------------- Skills ---------------- */

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  font-family: "Plex Mono", ui-monospace, monospace;
  font-size: 0.74rem;
  letter-spacing: 0.03em;
  padding: 0.35rem 0.65rem;
  border: 1.3px solid var(--line);
  border-radius: 5px;
  color: var(--text-dim);
  background: var(--panel);
}

/* ---------------- Share (business-card facsimile) ---------------- */

.share-card {
  max-width: 340px;
  margin: 0 auto;
  aspect-ratio: 85.6 / 54;
  background: var(--panel);
  border: 1.5px solid var(--line);
  border-radius: 10px;
  display: flex;
  align-items: center;
  gap: 1.1rem;
  padding: 1.1rem 1.3rem;
  box-shadow: 0 10px 24px -16px rgba(10, 47, 48, 0.35);
}

.share-card img {
  width: 84px;
  height: 84px;
  flex: none;
  image-rendering: pixelated;
  border-radius: 4px;
  border: 1px solid var(--line);
}

.share-card-text {
  min-width: 0;
}

.share-card-name {
  font-weight: 700;
  font-size: 1rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.share-card-role {
  font-size: 0.8rem;
  color: var(--text-dim);
  margin-top: 0.15rem;
}

.share-card-tag {
  margin-top: 0.6rem;
  font-family: "Plex Mono", ui-monospace, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-ink);
}

.share-actions {
  display: flex;
  justify-content: center;
  margin-top: 1.1rem;
}

.btn-outline {
  background: transparent;
  border-color: var(--line);
  color: var(--text);
}

.btn-outline:hover {
  border-color: var(--accent-ink);
  color: var(--accent-ink);
}

.copied-flash {
  color: var(--accent-ink);
}

/* ---------------- Footer ---------------- */

.footer {
  padding: 1.75rem 1.5rem 2.25rem;
  border-top: 1px solid var(--line);
  font-family: "Plex Mono", ui-monospace, monospace;
  font-size: 0.8rem;
  color: var(--text-dim);
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.footer a {
  text-decoration: none;
  color: var(--text);
  border-bottom: 1px solid var(--line);
}

.footer a:hover {
  border-color: var(--accent-ink);
  color: var(--accent-ink);
}

.footer .fine-print {
  color: #547069;
  font-size: 0.72rem;
  letter-spacing: 0.03em;
}


/* ---------------- Larger screens ---------------- */

@media (min-width: 720px) {
  .card {
    margin: 2.5rem auto;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 30px 60px -30px rgba(10, 47, 48, 0.35);
  }

  .hero {
    padding: 2.75rem 3rem 3.25rem;
  }

  .badge-photo {
    width: 68px;
    height: 68px;
  }

  .name-mark {
    width: 68px;
    height: 68px;
  }

  .section {
    padding-left: 3rem;
    padding-right: 3rem;
  }

  .footer {
    padding-left: 3rem;
    padding-right: 3rem;
  }
}
