/* ==========================================================
   Hariri Gold | NFC business card landing page
   ========================================================== */

/* IRANSans, self-hosted in fonts/ */
@font-face {
  font-family: "IRANSans";
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url("fonts/IRANSansWeb_Light.woff2") format("woff2");
}
@font-face {
  font-family: "IRANSans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("fonts/IRANSansWeb.woff2") format("woff2");
}
@font-face {
  font-family: "IRANSans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url("fonts/IRANSansWeb_Medium.woff2") format("woff2");
}
@font-face {
  font-family: "IRANSans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("fonts/IRANSansWeb_Bold.woff2") format("woff2");
}

:root {
  --bg: #121212;
  --surface: rgba(255, 236, 212, 0.035);
  --surface-hover: rgba(255, 236, 212, 0.065);
  --line: rgba(227, 198, 166, 0.16);
  --line-strong: rgba(227, 198, 166, 0.36);

  --gold-50: #fbf1e3;
  --gold-100: #f2dfc3;
  --gold-200: #e3c6a6;
  --gold-300: #cfab85;

  --text: #f2ebe2;
  --muted: #a99d8f;

  --grad-gold: linear-gradient(135deg, #f7e7ce 0%, #dfbd96 26%, #b38a61 52%, #e8cca8 76%, #c49d75 100%);
  --grad-line: linear-gradient(90deg, transparent, rgba(227, 198, 166, 0.45), transparent);

  --radius: 18px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  --font: "IRANSans", "IRANSansWeb", Vazirmatn, Tahoma, "Segoe UI", system-ui, sans-serif;
}

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

html {
  font-size: 100%;
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  min-height: 100svh;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.8;
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  -webkit-tap-highlight-color: transparent;
}

svg { width: 1em; height: 1em; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; flex: none; }
a { color: inherit; }
button { font: inherit; color: inherit; }

:focus-visible {
  outline: 2px solid var(--gold-200);
  outline-offset: 3px;
  border-radius: 12px;
}

/* ---------- Background: ambient glow + gold dust ---------- */
.backdrop {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
  background:
    radial-gradient(120% 60% at 50% 120%, rgba(179, 140, 102, 0.10), transparent 60%),
    radial-gradient(60% 40% at 50% -10%, rgba(227, 198, 166, 0.07), transparent 70%);
}

.dust span {
  position: absolute;
  top: 100%;
  left: var(--x);
  width: var(--s);
  height: var(--s);
  border-radius: 50%;
  background: radial-gradient(circle, #fff1d8 0%, #d9b48a 45%, transparent 70%);
  opacity: 0;
  will-change: transform, opacity;
  animation: rise var(--d) linear var(--delay) infinite;
}

@keyframes rise {
  0%   { transform: translate3d(0, 0, 0); opacity: 0; }
  12%  { opacity: var(--o); }
  80%  { opacity: var(--o); }
  100% { transform: translate3d(var(--dx), -110vh, 0); opacity: 0; }
}

/* ---------- Layout ---------- */
.page {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 560px;
  margin-inline: auto;
  padding:
    max(24px, env(safe-area-inset-top))
    max(18px, env(safe-area-inset-right))
    max(28px, env(safe-area-inset-bottom))
    max(18px, env(safe-area-inset-left));
}

/* ---------- Hero ---------- */
.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.hero__logo {
  position: relative;
  isolation: isolate;
  width: min(76vw, 330px, 44vh);
  width: min(76vw, 330px, 44svh);
  min-width: 200px;
  max-width: 100%;
  margin: 0;
  line-height: 0;
}

.hero__logo::before {
  content: "";
  position: absolute;
  inset: 4% -14% 10%;
  z-index: -1;
  background: radial-gradient(closest-side, rgba(214, 170, 120, 0.26), rgba(214, 170, 120, 0.08) 55%, transparent 100%);
  animation: breathe 6s ease-in-out infinite;
}

/* Subtle sheen across the logo, masked to the gold artwork only */
.hero__logo::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(105deg, transparent 42%, rgba(255, 244, 226, 0.55) 50%, transparent 58%) no-repeat;
  background-size: 260% 100%;
  background-position: 130% 0;
  -webkit-mask: url("assets/logo.webp") center / contain no-repeat;
  mask: url("assets/logo.webp") center / contain no-repeat;
  mix-blend-mode: soft-light;
  animation: sheen 7s var(--ease) 1.6s infinite;
}

.hero__logo img {
  display: block;
  width: 100%;
  height: auto;
}

@keyframes breathe {
  0%, 100% { opacity: 0.75; transform: scale(0.97); }
  50%      { opacity: 1;    transform: scale(1.03); }
}

@keyframes sheen {
  0%   { background-position: 130% 0; }
  35%  { background-position: -30% 0; }
  100% { background-position: -30% 0; }
}

.hero__tagline {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px 12px;
  margin: 14px 0 0;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--gold-200);
}

.hero__dot {
  width: 6px;
  height: 6px;
  background: var(--gold-300);
  transform: rotate(45deg);
}

.hero__intro {
  max-width: 34ch;
  margin: 6px auto 0;
  text-wrap: balance;
  font-size: 0.875rem;
  font-weight: 300;
  line-height: 1.9;
  color: var(--muted);
}

/* ---------- Quick actions ---------- */
.quick {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
  max-width: 400px;
  margin-top: 22px;
}

.quick__item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 4px 0;
  text-decoration: none;
  color: var(--gold-100);
}

.quick__icon {
  display: grid;
  place-items: center;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  border: 1px solid transparent;
  background:
    radial-gradient(circle at 50% 30%, #241e18, #151311) padding-box,
    var(--grad-gold) border-box;
  box-shadow: 0 10px 24px -14px rgba(0, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  color: var(--gold-200);
  font-size: 25px;
  transition: transform 0.35s var(--ease), box-shadow 0.35s var(--ease), color 0.35s;
}

.quick__label {
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.4;
  white-space: nowrap;
}

.quick__item:hover .quick__icon,
.quick__item:focus-visible .quick__icon {
  transform: translateY(-3px);
  color: var(--gold-50);
  box-shadow: 0 14px 28px -12px rgba(214, 170, 120, 0.45), inset 0 1px 0 rgba(255, 255, 255, 0.08);
}
.quick__item:active .quick__icon { transform: scale(0.94); }

/* ---------- Buttons ---------- */
.cta {
  display: grid;
  gap: 10px;
  width: 100%;
  max-width: 400px;
  margin-top: 22px;
}

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 54px;
  padding: 12px 20px;
  border: 0;
  border-radius: 14px;
  overflow: hidden;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.4;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease), background-color 0.3s, border-color 0.3s;
}
.btn svg { font-size: 1.3em; }
.btn span { white-space: nowrap; }
.btn:active { transform: scale(0.98); }

.btn--gold {
  color: #22180f;
  background: var(--grad-gold);
  box-shadow: 0 12px 30px -14px rgba(214, 170, 120, 0.7), inset 0 1px 0 rgba(255, 255, 255, 0.55);
}
.btn--gold svg { stroke-width: 1.9; }
.btn--gold::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, 0.55) 50%, transparent 65%);
  transform: translateX(110%);
  animation: btn-shine 5s var(--ease) 2.4s infinite;
}
.btn--gold:hover { transform: translateY(-2px); box-shadow: 0 18px 36px -14px rgba(214, 170, 120, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.55); }

@keyframes btn-shine {
  0%   { transform: translateX(110%); }
  30%  { transform: translateX(-110%); }
  100% { transform: translateX(-110%); }
}

.btn--ghost {
  color: var(--gold-100);
  background: var(--surface);
  border: 1px solid var(--line-strong);
}
.btn--ghost:hover { background: var(--surface-hover); border-color: var(--gold-300); }

/* ---------- Sections ---------- */
.section { margin-top: 38px; }

.section__title {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 14px;
  font-size: 0.95rem;
  font-weight: 700;
  line-height: 1.5;
  color: var(--gold-200);
  white-space: nowrap;
}
.section__title::before,
.section__title::after {
  content: "";
  flex: 1;
  height: 1px;
}
.section__title::before { background: linear-gradient(to left, var(--line-strong), transparent); }
.section__title::after  { background: linear-gradient(to right, var(--line-strong), transparent); }

.list { display: grid; gap: 10px; }

.row {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 74px;
  padding: 13px 16px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
  text-decoration: none;
  transition: transform 0.3s var(--ease), background-color 0.3s, border-color 0.3s;
}
.row:hover,
.row:focus-visible {
  transform: translateY(-2px);
  background: var(--surface-hover);
  border-color: var(--line-strong);
}
.row:active { transform: scale(0.99); }

.row__icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 46px;
  height: 46px;
  border-radius: 14px;
  background: linear-gradient(145deg, rgba(227, 198, 166, 0.18), rgba(227, 198, 166, 0.04));
  border: 1px solid var(--line);
  color: var(--gold-200);
  font-size: 22px;
}

.row__body {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-width: 0;
  line-height: 1.45;
}

.row__label {
  font-size: 0.8125rem;
  color: var(--muted);
}

.row__value {
  align-self: flex-start;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 1.0625rem;
  font-weight: 700;
  color: var(--gold-100);
}

.row__go {
  font-size: 18px;
  color: var(--gold-300);
  opacity: 0.6;
  transition: transform 0.3s var(--ease), opacity 0.3s;
}
.row:hover .row__go { transform: translateX(-4px); opacity: 1; }

/* ---------- Address ---------- */
.address {
  padding: 18px 16px 16px;
  border-radius: var(--radius);
  background: var(--surface);
  border: 1px solid var(--line);
}

.address__head {
  display: flex;
  align-items: flex-start;
  gap: 14px;
}

.address__text {
  flex: 1;
  min-width: 0;
  padding-top: 2px;
  font-style: normal;
  font-size: 1rem;
  line-height: 1.9;
  color: var(--text);
}
.address__text strong { color: var(--gold-100); font-weight: 700; white-space: nowrap; }

.btn-copy {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding: 8px 14px;
  min-height: 40px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: transparent;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--gold-100);
  cursor: pointer;
  transition: background-color 0.3s, border-color 0.3s;
}
.btn-copy svg { font-size: 16px; }
.btn-copy:hover { background: var(--surface-hover); border-color: var(--gold-300); }

.maps__label {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 18px 0 10px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 0.8125rem;
  color: var(--muted);
}
.maps__label svg { font-size: 15px; color: var(--gold-300); transform: scaleX(-1); }

.maps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.maps__btn {
  display: grid;
  place-items: center;
  min-height: 48px;
  padding: 8px 6px;
  border-radius: 12px;
  border: 1px solid var(--line-strong);
  background: rgba(227, 198, 166, 0.05);
  text-decoration: none;
  text-align: center;
  font-size: 0.9375rem;
  font-weight: 700;
  line-height: 1.3;
  white-space: nowrap;
  word-spacing: 0.2em;
  color: var(--gold-100);
  transition: transform 0.3s var(--ease), background-color 0.3s, border-color 0.3s, color 0.3s;
}
.maps__btn:hover,
.maps__btn:focus-visible {
  transform: translateY(-2px);
  color: #22180f;
  background: var(--gold-200);
  border-color: var(--gold-200);
}

/* ---------- Footer ---------- */
.footer {
  margin-top: 44px;
  text-align: center;
}

.footer__ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 12px;
}
.footer__ornament span { width: 64px; height: 1px; background: var(--grad-line); }
.footer__ornament i { width: 7px; height: 7px; background: var(--gold-300); transform: rotate(45deg); }

.footer__brand {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.footer__copy {
  margin: 2px 0 0;
  font-size: 0.75rem;
  color: var(--muted);
}

/* ---------- Toast ---------- */
.toast {
  position: fixed;
  z-index: 10;
  left: 50%;
  bottom: max(24px, calc(env(safe-area-inset-bottom) + 12px));
  max-width: calc(100% - 32px);
  padding: 10px 20px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: rgba(28, 24, 20, 0.92);
  -webkit-backdrop-filter: blur(10px);
  backdrop-filter: blur(10px);
  box-shadow: 0 16px 40px -16px rgba(0, 0, 0, 0.9);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--gold-100);
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transform: translate(-50%, 16px);
  transition: opacity 0.3s, transform 0.3s var(--ease), visibility 0.3s;
}
.toast.is-visible { opacity: 1; visibility: visible; transform: translate(-50%, 0); }

/* ---------- Entrance animation ---------- */
.reveal {
  opacity: 0;
  animation: reveal 0.9s var(--ease) forwards;
  animation-delay: calc(var(--i, 0) * 90ms + 80ms);
}
@keyframes reveal {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: none; }
}

/* ==========================================================
   Responsive
   ========================================================== */

/* Very small phones (Galaxy Fold, etc.) */
@media (max-width: 340px) {
  html { font-size: 93.75%; }
  .page { padding-inline: max(12px, env(safe-area-inset-left)) max(12px, env(safe-area-inset-right)); }
  .quick { gap: 4px; }
  .quick__icon { width: 52px; height: 52px; font-size: 22px; }
  .quick__label { font-size: 0.75rem; }
  .row { gap: 10px; padding: 12px; }
  .row__icon { width: 40px; height: 40px; font-size: 19px; border-radius: 12px; }
  .row__go { display: none; }
  .address { padding: 16px 12px 12px; }
  .address__head { gap: 10px; }
  .maps { gap: 6px; }
  .maps__btn { font-size: 0.875rem; padding-inline: 4px; }
}

@media (max-width: 300px) {
  .quick__icon { width: 48px; height: 48px; font-size: 20px; }
  .hero__logo { min-width: 0; }
}

/* Tablet */
@media (min-width: 600px) {
  html { font-size: 106.25%; }
  .page { max-width: 660px; padding-top: max(48px, env(safe-area-inset-top)); }
  .list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero__intro { font-size: 0.9375rem; }
  /* Copy button beside the address instead of under it */
  .address { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; column-gap: 16px; }
  .address__head { align-items: center; }
  .btn-copy { margin-top: 0; }
  .maps__label, .maps { grid-column: 1 / -1; }
}

/* Phone in landscape (short viewport) */
@media (orientation: landscape) and (max-height: 520px) {
  html { font-size: 100%; }
  .page { padding-top: max(16px, env(safe-area-inset-top)); }
  .hero__logo { width: min(42vw, 240px, 62vh); width: min(42vw, 240px, 62svh); min-width: 0; }
}

/* Desktop: logo column on the right, details on the left */
@media (min-width: 1180px) {
  .page {
    display: grid;
    grid-template-columns: minmax(380px, 440px) minmax(0, 600px);
    grid-template-rows: 1fr auto;
    justify-content: center;
    align-items: center;
    column-gap: clamp(48px, 7vw, 120px);
    max-width: 1240px;
    min-height: 100vh;
    min-height: 100svh;
    padding: 48px 40px 28px;
  }
  /* Size the logo by viewport height so the buttons stay above the fold */
  .hero__logo { width: min(360px, max(230px, calc((100vh - 440px) * 0.83))); min-width: 0; }
  .quick, .cta { max-width: none; }
  .cta { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cta .btn { padding-inline: 12px; font-size: 0.9375rem; gap: 8px; }
  .cta__more { display: none; }
  .content .section:first-child { margin-top: 0; }
  .footer { grid-column: 1 / -1; margin-top: 48px; }
}

/* Large screens */
@media (min-width: 1600px) {
  html { font-size: 112.5%; }
  .page { grid-template-columns: minmax(420px, 500px) minmax(0, 680px); max-width: 1440px; }
  .hero__logo { width: min(420px, max(260px, calc((100vh - 500px) * 0.83))); }
  .quick__icon { width: 68px; height: 68px; font-size: 28px; }
  .row { min-height: 84px; }
  .row__icon { width: 52px; height: 52px; font-size: 24px; }
}

/* QHD and 4K monitors at 100% scaling */
@media (min-width: 2200px) {
  html { font-size: 137.5%; }
  .page {
    grid-template-columns: minmax(520px, 600px) minmax(0, 860px);
    column-gap: 160px;
    max-width: 1760px;
    padding: 64px 56px 36px;
  }
  .hero__logo { width: min(520px, max(300px, calc((100vh - 640px) * 0.83))); }
  .quick__icon { width: 86px; height: 86px; font-size: 34px; }
  .btn { min-height: 66px; border-radius: 16px; }
  .section { margin-top: 48px; }
  .list { gap: 14px; }
  .row { min-height: 106px; padding: 18px 22px; gap: 18px; border-radius: 22px; }
  .row__icon { width: 64px; height: 64px; font-size: 30px; border-radius: 18px; }
  .row__go { font-size: 22px; }
  .address { padding: 24px 22px 22px; border-radius: 22px; }
  .btn-copy { min-height: 50px; padding-inline: 18px; }
  .btn-copy svg { font-size: 20px; }
  .maps__btn { min-height: 62px; border-radius: 14px; }
  .footer__ornament span { width: 96px; }
  .footer__ornament i { width: 9px; height: 9px; }
  .hero__tagline { gap: 6px 16px; }
  .hero__dot { width: 8px; height: 8px; }
  .maps__label svg { font-size: 18px; }
}

/* Respect the reduced-motion preference */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; animation: none; }
  .dust { display: none; }
}

@media print {
  .backdrop, .cta, .toast { display: none; }
  .reveal { opacity: 1; animation: none; }
}
