/* =================================================================
   abdulosama.com — Link Hub
   Standalone, mobile-first, design-system native. Loads tokens.css
   for variables + fonts; everything else lives here. No Vite, no
   framework JS — the page is a gradient fold + a column of cards.
   ================================================================= */

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body.hub-body {
  direction: rtl;
  font-family: var(--font-body);
  background: var(--abdul-gradient-paper);
  background-attachment: fixed;
  color: var(--fg-primary);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ===== HERO FOLD — the gradient crown ===== */
.hub-hero {
  position: relative;
  overflow: hidden;
  background: var(--abdul-gradient-radial-glow);
  color: #fff;
  text-align: center;
  padding: 64px 24px 104px;
}
/* Sky mode: stars replace the static streaks (sky.js). */
.hub-hero[data-sky]::after { display: none; }
.hub-hero[data-sky] > * { position: relative; z-index: 1; }
/* Language toggle — quiet, pinned to the top-inline-end corner.
   Selector must out-specify `.hub-hero[data-sky] > *` (which sets
   position:relative on every hero child), or the pill falls into the
   centered flow instead of the corner. */
.hub-hero[data-sky] .hub-lang,
.hub-lang {
  position: absolute; top: 16px; inset-inline-end: 16px; z-index: 3;
  display: inline-flex; align-items: center;
  padding: 5px 12px; border-radius: 999px;
  border: 1.5px solid rgba(255,255,255,.35);
  color: #fff; text-decoration: none;
  font-size: 12.5px; font-weight: 700;
  transition: border-color 160ms var(--ease-standard), background 160ms var(--ease-standard);
}
.hub-lang:hover { border-color: #fff; background: rgba(255,255,255,.12); }

/* Rain streaks — thin luminous verticals, straight from the LP kit. */
.hub-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    linear-gradient(to bottom, transparent, rgba(255,255,255,0.16) 40%, transparent 80%),
    linear-gradient(to bottom, transparent 10%, rgba(52,224,232,0.30) 50%, transparent 85%),
    linear-gradient(to bottom, transparent 5%, rgba(255,255,255,0.10) 45%, transparent 90%);
  background-size: 2px 100%, 3px 100%, 2px 100%;
  background-position: 20% 0, 70% 0, 88% 0;
  background-repeat: no-repeat;
}
.hub-avatar {
  width: 104px;
  height: 104px;
  border-radius: 50%;
  border: 3.5px solid rgba(255, 255, 255, 0.92);
  box-shadow: 0 14px 36px rgba(7, 5, 28, 0.38);
  object-fit: cover;
  position: relative;
  z-index: 1;
}
.hub-name {
  position: relative;
  z-index: 1;
  font-family: var(--font-arabic-display);
  font-feature-settings: var(--ff-swash);
  font-weight: 900;
  font-size: clamp(30px, 8vw, 42px);
  line-height: 1.25;
  margin: 18px 0 10px;
  color: #fff;
  text-wrap: balance;
}
.hub-bio {
  position: relative;
  z-index: 1;
  font-size: 16.5px;
  line-height: 1.75;
  color: rgba(255, 255, 255, 0.88);
  max-width: 36ch;
  margin: 0 auto;
  text-wrap: pretty;
}

/* ===== LINK CARDS — the narrow column, overlapping the fold ===== */
.hub-links {
  width: 100%;
  max-width: 560px;
  margin: -60px auto 0;
  padding: 0 18px 48px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  position: relative;
  z-index: 2;
  flex: 1;
}
.hub-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--abdul-gradient-raised);
  border: 1px solid var(--border-subtle);
  border-radius: var(--r-xl);
  padding: 14px 16px;
  min-height: 76px;
  text-decoration: none;
  color: var(--fg-primary);
  box-shadow: var(--shadow-sm);
  transition:
    transform var(--dur-base) var(--ease-standard),
    box-shadow var(--dur-base) var(--ease-standard),
    border-color var(--dur-base) var(--ease-standard);
  animation: hub-up var(--dur-slow) var(--ease-entrance) both;
}
.hub-card:nth-child(1) { animation-delay: 40ms; }
.hub-card:nth-child(2) { animation-delay: 90ms; }
.hub-card:nth-child(3) { animation-delay: 140ms; }
.hub-card:nth-child(4) { animation-delay: 190ms; }
.hub-card:nth-child(5) { animation-delay: 240ms; }
.hub-card:nth-child(6) { animation-delay: 290ms; }
.hub-card:nth-child(7) { animation-delay: 340ms; }
.hub-card:nth-child(n+8) { animation-delay: 380ms; }
@keyframes hub-up {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: translateY(0); }
}
.hub-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--abdul-salmon-500);
}
.hub-card:active { transform: translateY(0); }

/* Icon tile — 5th-color rotation via accent classes. */
.hub-card-ic {
  width: 48px;
  height: 48px;
  border-radius: var(--r-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  flex-shrink: 0;
  box-shadow: var(--shadow-xs);
}
.hub-card-ic svg { width: 22px; height: 22px; }
.ic-violet  { background: var(--abdul-gradient-violet); }
.ic-salmon  { background: var(--abdul-gradient-salmon); }
.ic-mint    { background: var(--abdul-gradient-mint); color: #06241a; }
.ic-cyan    { background: var(--abdul-gradient-cyan); color: #0a2540; }
.ic-ink     { background: var(--abdul-gradient-ink); }
.ic-sunset  { background: linear-gradient(150deg, #ff9466 0%, #f5536a 55%, #5a16e6 100%); }

.hub-card-body { min-width: 0; }
.hub-card-title {
  font-family: var(--font-arabic);
  font-weight: 700;
  font-size: 16.5px;
  line-height: 1.35;
}
.hub-card-sub {
  font-size: 13px;
  color: var(--fg-tertiary);
  line-height: 1.5;
  margin-top: 2px;
}
.hub-card-arrow {
  margin-inline-start: auto;
  color: var(--fg-muted);
  display: flex;
  align-items: center;
  transition: color var(--dur-base), transform var(--dur-base) var(--ease-standard);
  flex-shrink: 0;
}
.hub-card:hover .hub-card-arrow {
  color: var(--abdul-salmon-600);
  transform: translateX(-3px); /* RTL: forward = left */
}

/* Coming-soon variant — visible but not clickable. */
.hub-card.is-soon {
  border-style: dashed;
  cursor: default;
  opacity: 0.85;
}
.hub-card.is-soon:hover {
  transform: none;
  box-shadow: var(--shadow-sm);
  border-color: var(--border-subtle);
}
.hub-soon-chip {
  margin-inline-start: auto;
  flex-shrink: 0;
  font-size: 11.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  padding: 4px 12px;
  border-radius: var(--r-pill);
  background: var(--abdul-gradient-mint);
  color: #06241a;
}

/* ===== FOOTER ===== */
.hub-foot {
  text-align: center;
  font-size: 12.5px;
  color: var(--fg-tertiary);
  padding: 0 20px 36px;
}
.hub-foot a { color: inherit; text-decoration: none; }
.hub-foot a:hover { color: var(--abdul-salmon-600); }

@media (prefers-reduced-motion: reduce) {
  .hub-card { animation: none; }
  .hub-card, .hub-card-arrow { transition: none; }
}

/* ---- Temporary Rivo Host promo card — sticker look matching the ريفو
   logo (white, thick ink outline, hard shadow, slight tilt). Remove by
   hiding the `rivo` link in Filament. ---- */
.hub-card.is-rivo {
  background: #fff;
  border: 3px solid #131313;
  box-shadow: 4px 5px 0 #131313;
  transform: rotate(-1.2deg);
  position: relative;
}
.hub-card.is-rivo:hover { transform: rotate(0deg) translateY(-2px); box-shadow: 5px 7px 0 #131313; }
.hub-card.is-rivo .hub-card-title { color: #131313; }
.hub-card.is-rivo .hub-card-sub { color: #4a4a4a; }
.hub-card.is-rivo .hub-card-arrow { color: #131313; }
.hub-rivo-logo { width: 86px; height: auto; flex: 0 0 auto; }
.hub-card.is-rivo::after {
  content: 'جديد';
  position: absolute;
  top: -13px;
  inset-inline-start: 16px;
  background: var(--abdul-gradient-salmon, linear-gradient(90deg, #f5536a, #ff8a5c));
  color: #fff;
  font-size: 12px;
  font-weight: 800;
  padding: 3px 13px;
  border-radius: 999px;
  border: 2px solid #131313;
}
@media (prefers-reduced-motion: reduce) {
  .hub-card.is-rivo, .hub-card.is-rivo:hover { transform: none; }
}
