/* ============================================================
   FikraBits — landing page
   Palette extracted from the brand mark:
   ------------------------------------------------------------
   --bg-deep    #170c14  dark variation of the plum background
   --bg-plum    #2d1b2e  logo background plum
   --accent     #d0a2ba  dusty mauve/pink ("Bits" + bulb bits)
   --accent-dim #b98aa4  darker mauve for hovers
   --cream      #f0ebe4  off-white ("Fikra")
   ============================================================ */

:root {
  --bg-deep: #170c14;
  --bg-plum: #2d1b2e;
  --accent: #d0a2ba;
  --accent-dim: #b98aa4;
  --cream: #f0ebe4;
  --muted: #b9a9b3;

  --card-bg: rgba(45, 27, 46, 0.55);
  --card-border: rgba(208, 162, 186, 0.22);
  --field-bg: rgba(23, 12, 20, 0.55);

  --font-en: 'Poppins', system-ui, -apple-system, sans-serif;
  --font-ar: 'Tajawal', system-ui, -apple-system, sans-serif;

  --radius: 16px;
  --maxw: 620px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: var(--font-en);
  color: var(--cream);
  background:
    radial-gradient(1200px 600px at 15% -10%, rgba(208, 162, 186, 0.14), transparent 60%),
    radial-gradient(900px 500px at 100% 110%, rgba(185, 138, 164, 0.12), transparent 55%),
    linear-gradient(160deg, var(--bg-deep) 0%, #1f1020 55%, var(--bg-plum) 100%);
  background-attachment: fixed;
  line-height: 1.6;
  overflow-x: hidden;
}

html[dir="rtl"] body { font-family: var(--font-ar); }

/* ---------- decorative "bits" ---------- */
.bits-field {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.5;
}
.bit {
  position: absolute;
  background: var(--accent);
  border-radius: 3px;
  opacity: 0;
  animation: floatBit linear infinite;
}
@keyframes floatBit {
  0%   { transform: translateY(30px) rotate(0deg);   opacity: 0; }
  15%  { opacity: 0.55; }
  85%  { opacity: 0.55; }
  100% { transform: translateY(-40px) rotate(120deg); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .bit { animation: none; opacity: 0.25; }
}

/* ---------- layout ---------- */
.topbar,
.hero,
.footer { position: relative; z-index: 1; }

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px clamp(20px, 5vw, 56px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: clamp(1.4rem, 2.6vw, 1.75rem);
  letter-spacing: 0.5px;
}
.brand-mark {
  width: clamp(2.1rem, 4.2vw, 2.75rem);
  height: auto;
  color: var(--accent);
  flex-shrink: 0;
}
.brand-light { color: var(--cream); font-weight: 500; }
.brand-accent { color: var(--accent); font-weight: 700; }

.lang-btn {
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--cream);
  background: rgba(208, 162, 186, 0.10);
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 8px 18px;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.15s ease;
}
.lang-btn:hover { background: rgba(208, 162, 186, 0.20); border-color: var(--accent); }
.lang-btn:active { transform: scale(0.96); }
.lang-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- hero ---------- */
.hero {
  flex: 1;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: clamp(24px, 6vh, 64px) clamp(20px, 5vw, 56px);
}
.hero-inner {
  width: 100%;
  max-width: var(--maxw);
  text-align: center;
}

.badge {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--accent);
  background: rgba(208, 162, 186, 0.12);
  border: 1px solid var(--card-border);
  border-radius: 999px;
  padding: 7px 16px;
  margin-bottom: 22px;
}

.headline {
  font-size: clamp(1.9rem, 5.5vw, 3.1rem);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 16px;
  padding-bottom: 0.12em;
  background: linear-gradient(120deg, var(--cream) 30%, var(--accent) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.subhead {
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  color: var(--muted);
  max-width: 32em;
  margin: 0 auto 40px;
}

/* ---------- contact card ---------- */
.contact-card {
  text-align: start;
  background: var(--card-bg);
  border: 1px solid var(--card-border);
  border-radius: var(--radius);
  padding: clamp(22px, 4vw, 34px);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 20px 60px -20px rgba(0, 0, 0, 0.6);
}

.form-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 20px;
  color: var(--cream);
}

.field { margin-bottom: 16px; }

.field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 7px;
  color: var(--muted);
}

.field input,
.field textarea {
  width: 100%;
  font-family: inherit;
  font-size: 0.98rem;
  color: var(--cream);
  background: var(--field-bg);
  border: 1px solid var(--card-border);
  border-radius: 10px;
  padding: 12px 14px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  resize: vertical;
}
.field input::placeholder,
.field textarea::placeholder { color: rgba(185, 169, 179, 0.6); }

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(208, 162, 186, 0.18);
}

.field input:invalid:not(:placeholder-shown),
.field textarea:invalid:not(:placeholder-shown) {
  border-color: #d98a8a;
}

.cta {
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  color: var(--bg-deep);
  background: linear-gradient(120deg, var(--accent) 0%, var(--accent-dim) 100%);
  border: none;
  border-radius: 10px;
  padding: 14px 18px;
  margin-top: 6px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.2s ease, filter 0.2s ease;
}
.cta:hover { filter: brightness(1.07); box-shadow: 0 10px 30px -8px rgba(208, 162, 186, 0.5); }
.cta:active { transform: translateY(1px) scale(0.99); }
.cta:focus-visible { outline: 2px solid var(--cream); outline-offset: 2px; }

.form-note {
  margin-top: 14px;
  font-size: 0.9rem;
  min-height: 1.2em;
  color: var(--accent);
  text-align: center;
}

/* ---------- footer ---------- */
.footer {
  text-align: center;
  padding: 26px 20px 34px;
  font-size: 0.88rem;
  color: var(--muted);
}

/* ---------- responsive ---------- */
@media (max-width: 480px) {
  .topbar { padding: 18px 20px; }
  .subhead { margin-bottom: 30px; }
}
