/* ceo-ibrahem.diano.si — Diano "Ink" ground (docs/brand/visual-identity.md §12) with a personal, editorial identity.
   One accent: sunflower. Fonts are Diano's self-hosted OFL set (fonts/*-OFL.txt). */

@font-face { font-family: 'Inter'; font-weight: 100 900; font-display: swap; src: url('fonts/InterVariable-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2190-2193, U+2212, U+2215, U+2713, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Sans Arabic'; font-weight: 400; font-display: swap; src: url('fonts/IBMPlexSansArabic-Regular.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Sans Arabic'; font-weight: 500; font-display: swap; src: url('fonts/IBMPlexSansArabic-Medium.woff2') format('woff2'); }
@font-face { font-family: 'IBM Plex Sans Arabic'; font-weight: 600 900; font-display: swap; src: url('fonts/IBMPlexSansArabic-SemiBold.woff2') format('woff2'); }
@font-face { font-family: 'JetBrains Mono'; font-weight: 400; font-display: swap; src: url('fonts/JetBrainsMono-Regular.woff2') format('woff2'); }

:root {
  --ground: #0F0E0C;
  --side: #141311;
  --card: #1B1917;
  --card-2: #24221E;
  --text: #ECE6DA;
  --cream: #F6F1E7;
  --muted: rgb(236 230 218 / 0.68);
  --subtle: rgb(236 230 218 / 0.56);
  --edge: rgb(236 230 218 / 0.17);
  --edge-strong: rgb(236 230 218 / 0.38);
  --sun: #FFC933;
  --ok: #3DBE7A;
  --err: #FF5A5F;
  --sans: 'Inter', 'IBM Plex Sans Arabic', system-ui, sans-serif;
  --mono: 'JetBrains Mono', 'IBM Plex Sans Arabic', ui-monospace, 'Cascadia Mono', Consolas, monospace;
  --gutter: clamp(16px, 4.5vw, 64px);
  --max: 1240px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--text);
  font: 400 17px/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
html[lang="en"] body { line-height: 1.6; }
/* page-wide film grain */
body::after {
  content: ''; position: fixed; inset: 0; pointer-events: none; z-index: 50; opacity: .07; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
img { display: block; max-width: 100%; height: auto; }
[hidden] { display: none !important; } /* .btn etc. set display, which would otherwise beat the attribute */
a { color: inherit; }
b { font-weight: 600; color: var(--cream); }
.mono { font-family: var(--mono); font-size: .8125rem; letter-spacing: .02em; }
/* letter-spacing breaks Arabic joining; Arabic labels also read better a step larger */
html[lang="ar"] .mono { letter-spacing: 0; font-size: .875rem; }
::selection { background: var(--sun); color: #111; }
:focus-visible { outline: 2px solid var(--sun); outline-offset: 3px; border-radius: 6px; }

.skip { position: absolute; inset-inline-start: 16px; top: -60px; background: var(--sun); color: #111; padding: 8px 14px; border-radius: 8px; z-index: 100; }
.skip:focus { top: 12px; }

/* ── top bar ─────────────────────────────────────────── */
.bar {
  position: sticky; top: 0; z-index: 40;
  display: flex; align-items: center; gap: 16px;
  padding: 14px var(--gutter);
  background: color-mix(in srgb, var(--ground) 78%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s;
}
.bar.scrolled { border-bottom-color: var(--edge); }
.bar-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; color: var(--cream); font-family: 'Inter', sans-serif; }
.mark { width: 22px; height: 20px; fill: currentColor; }
.bar-clock { margin: 0 auto 0 0; display: flex; align-items: center; gap: 8px; color: var(--subtle); }
html[dir="ltr"] .bar-clock { margin: 0 0 0 auto; }
.bar-clock time { color: var(--text); font-variant-numeric: tabular-nums; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 3px rgb(61 190 122 / .18); }
.lang {
  font: 600 .8125rem/1 var(--mono); letter-spacing: .06em;
  color: var(--text); background: var(--card); border: 1px solid var(--edge-strong);
  border-radius: 999px; padding: 9px 14px; min-width: 48px; min-height: 36px; cursor: pointer;
}
.lang:hover { border-color: var(--sun); color: var(--sun); }

/* ── hero: founder ID badge on an elastic Diano strap (badge.js) ── */
.hero {
  position: relative; max-width: var(--max); margin: 0 auto; min-height: calc(100svh - 64px);
  padding: clamp(24px, 5vw, 64px) var(--gutter) clamp(48px, 7vw, 96px);
  display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(24px, 5vw, 64px); align-items: stretch;
  overflow-x: clip; overflow-y: visible; /* the badge may hang or be dragged below the hero, never sideways out of the page */
}
.hero-text { align-self: center; position: relative; z-index: 1; }
.kicker { color: var(--sun); margin: 0 0 18px; text-transform: uppercase; }
.name { margin: 0; color: var(--cream); font-weight: 700; line-height: .95; font-size: clamp(4.5rem, 12vw, 11rem); padding-bottom: .06em; }
html[lang="en"] .name { font-weight: 800; letter-spacing: -.055em; }
.hero .thesis { margin-top: 22px; }
.hero .cta { margin-top: 28px; }

.hang-slot { position: relative; min-height: 760px; display: grid; align-content: end; justify-items: center; gap: 12px; padding-bottom: 8px; }
.rig-hint { margin: 0; color: var(--subtle); font-size: .78rem; text-align: center; transition: opacity .4s; }
.rig-hint.used { opacity: .45; }
.rig-reset { position: relative; z-index: 6; }
.rig { position: absolute; inset: 0; pointer-events: none; z-index: 5; }
.rig-svg { position: absolute; left: 0; top: 0; overflow: visible; direction: ltr; } /* SVG textPath renders nothing under rtl */
.rig-top { z-index: 1; }
.rig-svg .rt { fill: #111; font: 800 10px 'Inter', sans-serif; letter-spacing: .2em; }
.rig-svg .hook { fill: #3a3730; stroke: rgb(236 230 218 / .3); }
.rig-svg .rb { filter: drop-shadow(0 2px 2px rgb(0 0 0 / .35)); }
.hero.snapped .rig-svg { animation: snapFlash .25s ease-out; }
@keyframes snapFlash { 0% { filter: brightness(2); } 100% { filter: none; } }

.badge {
  position: absolute; left: 0; top: 0; width: min(74vw, 300px); background: #F6F1E7; color: #111; border-radius: 18px; padding: 24px 16px 16px;
  box-shadow: 0 40px 70px -25px rgb(0 0 0 / .9), inset 0 0 0 1px rgb(0 0 0 / .08); transform-origin: 50% 50%; will-change: transform;
  pointer-events: auto; cursor: grab; touch-action: none; user-select: none; -webkit-user-select: none;
}
.badge.grabbing { cursor: grabbing; }
.badge img { display: block; width: 100%; object-fit: cover; pointer-events: none; -webkit-user-drag: none; }
.badge .clip { position: absolute; top: -14px; left: 50%; translate: -50% 0; width: 54px; height: 24px; border-radius: 6px; background: linear-gradient(#d9d4c8, #a9a395); box-shadow: 0 2px 4px rgb(0 0 0 / .3); }
.badge .clip::after { content: ''; position: absolute; left: 50%; top: 8px; translate: -50% 0; width: 22px; height: 6px; border-radius: 3px; background: #111; }
.b-top { display: flex; align-items: center; gap: 8px; font-weight: 700; direction: ltr; }
.b-top .mark { fill: #111; }
.b-top .no { margin-left: auto; font-size: .78rem; color: #6a6458; }
.b-ph { margin-top: 14px; aspect-ratio: 1; height: auto; border-radius: 10px; object-position: 50% 8%; }
.b-name { margin: 14px 0 0; font-size: 2.3rem; font-weight: 700; line-height: 1; }
html[lang="en"] .b-name { font-weight: 800; letter-spacing: -.04em; }
.b-role { margin: 6px 0 0; color: #6a6458; letter-spacing: .12em; }
.b-row { display: flex; justify-content: space-between; margin-top: 14px; padding-top: 12px; border-top: 1.5px dashed rgb(0 0 0 / .2); font-size: .74rem; color: #6a6458; }
.b-row b { color: #111; }
.b-bar { margin-top: 12px; height: 30px; background: repeating-linear-gradient(90deg, #111 0 2px, transparent 2px 4px, #111 4px 7px, transparent 7px 9px, #111 9px 10px, transparent 10px 13px); }
/* until badge.js has placed it, keep the badge out of sight (it would flash at the corner) */
.js .hero:not(.rig-ready) .badge { visibility: hidden; }
/* no JavaScript: a still badge standing in its column, no strap */
html:not(.js) .rig { position: static; grid-column: 2; grid-row: 1; display: grid; place-items: end center; pointer-events: auto; }
html:not(.js) .rig-svg, html:not(.js) .hang-slot { display: none; }
html:not(.js) .badge { position: relative; cursor: auto; }


.thesis { max-width: 34ch; margin: 28px 0 0; font-size: clamp(1.15rem, 1.9vw, 1.45rem); line-height: 1.65; color: var(--text); }
mark { background: linear-gradient(transparent 62%, rgb(255 201 51 / .38) 62%); color: var(--cream); padding: 0 .1em; }
.cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 48px; padding: 12px 22px; border-radius: 12px;
  font: 600 1rem/1.2 var(--sans); text-decoration: none; cursor: pointer;
  border: 1.5px solid var(--edge-strong); background: transparent; color: var(--text);
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s, background .15s;
}
.btn-primary { background: var(--sun); color: #111; border-color: #111; box-shadow: 4px 4px 0 var(--cream); }
html[dir="rtl"] .btn-primary { box-shadow: -4px 4px 0 var(--cream); }
.btn-primary:hover { transform: translate(-1px, -1px); box-shadow: 6px 6px 0 var(--cream); }
html[dir="rtl"] .btn-primary:hover { transform: translate(1px, -1px); box-shadow: -6px 6px 0 var(--cream); }
.btn-ghost:hover { border-color: var(--sun); color: var(--sun); }
html[dir="rtl"] .arrow { display: inline-block; transform: scaleX(-1); }

/* ── sections ────────────────────────────────────────── */
.section { max-width: var(--max); margin: 0 auto; padding: clamp(64px, 10vw, 128px) var(--gutter) 0; }
.eyebrow { color: var(--sun); margin: 0 0 14px; }
.h2 { margin: 0 0 clamp(28px, 4vw, 48px); color: var(--cream); font-weight: 700; font-size: clamp(2rem, 5vw, 3.6rem); line-height: 1.15; letter-spacing: -.01em; max-width: 22ch; text-wrap: balance; }
html[lang="en"] .h2 { letter-spacing: -.035em; font-weight: 750; }
.h2.big { font-size: clamp(2.2rem, 6.4vw, 5rem); max-width: 18ch; }
.hl { color: var(--sun); }
.lede { margin: -16px 0 36px; color: var(--muted); max-width: 56ch; }

/* footer */
.foot {
  max-width: var(--max); margin: 0 auto; padding: 28px var(--gutter) calc(28px + env(safe-area-inset-bottom));
  display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; border-top: 1px solid var(--edge); color: var(--subtle);
}
.foot p { margin: 0; }
.foot p:last-child { margin-inline-start: auto; }

/* ── motion (JS adds .js; reduced motion turns it all off) ── */
.js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .2, 1); }
.js [data-reveal].in { opacity: 1; transform: none; }
.js .hero-text > * { animation: rise .8s cubic-bezier(.2, .7, .2, 1) both; }
.js .hero-text > :nth-child(2) { animation-delay: .08s; }
.js .hero-text > :nth-child(3) { animation-delay: .16s; }
.js .hero-text > :nth-child(4) { animation-delay: .24s; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal] { opacity: 1; transform: none; transition: none; }
  .js .hero-text > * { animation: none; }
  .btn, .rig-hint { transition: none; }
  .hero.snapped .rig-svg { animation: none; }
}

/* ── responsive ──────────────────────────────────────── */
@media (max-width: 860px) {
  body { font-size: 16px; }
  .hero { grid-template-columns: 1fr; min-height: 0; padding-top: 12px; }
  .hang-slot { order: -1; min-height: 660px; }
  html:not(.js) .rig { grid-column: 1; grid-row: 1; }
  .kicker { margin-bottom: 8px; }
}
@media (max-width: 480px) {
  .bar { gap: 10px; }
  .bar-clock [data-i18n="clock"] { display: none; }
  .cta .btn { flex: 1 1 100%; }
  .foot p:last-child { margin-inline-start: 0; width: 100%; }
}
