/* WJ Site — Gold & Black Theme */
:root {
  --background: #050505;
  --foreground: #f5f0e6;
  --gold: #c9a227;
  --gold-light: #e8d48b;
  --gold-dark: #8a6d1a;
  --surface: #111111;
  --surface-elevated: #1a1a1a;
  --border: rgba(201, 162, 39, 0.25);
  --font: system-ui, -apple-system, "Segoe UI", sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font);
  line-height: 1.6;
  min-height: 100vh;
}

[dir="rtl"] body { font-family: "Segoe UI", Tahoma, Arial, sans-serif; }

a { color: inherit; text-decoration: none; }

img { max-width: 100%; display: block; }

.container { max-width: 80rem; margin: 0 auto; padding: 0 1.5rem; }

.gold-gradient {
  background: linear-gradient(135deg, var(--gold-light), var(--gold), var(--gold-dark));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.gold-glow { box-shadow: 0 0 40px rgba(201, 162, 39, 0.15); }

.text-muted { color: rgba(245, 240, 230, 0.6); }
.text-faint { color: rgba(245, 240, 230, 0.4); }

/* Header */
.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  backdrop-filter: blur(12px);
  background: rgba(0,0,0,0.7);
  border-bottom: 1px solid var(--border);
}
.site-header .inner {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 4.5rem; padding: 0.5rem 0;
}
.logo-link { display: flex; align-items: center; gap: 0.75rem; }
.logo-img {
  width: 2.25rem; height: 2.25rem; border-radius: 0.5rem;
  border: 1px solid var(--border); object-fit: contain; background: #fff;
}
.logo-text { display: flex; flex-direction: column; line-height: 1.2; }
.logo-name { font-weight: 700; font-size: 0.875rem; }
.logo-sub { font-size: 0.625rem; letter-spacing: 0.15em; text-transform: uppercase; color: rgba(245,240,230,0.5); }

.main-nav { display: none; gap: 2rem; }
.main-nav a { font-size: 0.875rem; color: rgba(245,240,230,0.7); transition: color 0.2s; }
.main-nav a:hover { color: var(--gold); }

.header-actions { display: flex; align-items: center; gap: 1rem; }
.btn-lang {
  font-size: 0.75rem; padding: 0.375rem 0.75rem;
  border: 1px solid var(--border); border-radius: 0.25rem;
  color: var(--gold); background: transparent; cursor: pointer;
}
.btn-lang:hover { background: rgba(201,162,39,0.1); }
.admin-link { font-size: 0.75rem; color: rgba(245,240,230,0.4); }
.admin-link:hover { color: rgba(245,240,230,0.7); }

@media (min-width: 768px) { .main-nav { display: flex; } }

/* 3D Canvas */
#scene-canvas {
  position: fixed; inset: 0; z-index: 0; width: 100%; height: 100%;
}

/* Journey */
.journey-section { position: relative; }
.journey-scroll { position: relative; z-index: 10; }
.journey-sticky {
  position: sticky; top: 0; height: 100vh;
  display: flex; align-items: center; pointer-events: none;
}
.journey-grid {
  display: grid; gap: 3rem; align-items: center; width: 100%;
}
@media (min-width: 1024px) { .journey-grid { grid-template-columns: 1fr 1fr; } }

.journey-hero { pointer-events: auto; }
.hero-logo {
  width: 7.5rem; height: 7.5rem; border-radius: 0.75rem;
  border: 1px solid rgba(201,162,39,0.3);
  box-shadow: 0 0 40px rgba(201,162,39,0.2);
  margin-bottom: 1.5rem; object-fit: contain; background: #fff;
}
.eyebrow {
  font-size: 0.75rem; letter-spacing: 0.3em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 1rem;
}
.hero-title { font-size: clamp(2.25rem, 5vw, 3.75rem); font-weight: 700; line-height: 1.1; margin-bottom: 1.5rem; }
.hero-tagline { font-size: 1.125rem; max-width: 28rem; }
.scroll-hint { margin-top: 2rem; display: flex; align-items: center; gap: 0.5rem; font-size: 0.75rem; }
.bounce { animation: bounce 1.5s infinite; }
@keyframes bounce { 0%,100%{transform:translateY(0)} 50%{transform:translateY(4px)} }

.milestone-card {
  pointer-events: auto;
  border-radius: 1rem; padding: 2rem;
  background: rgba(17,17,17,0.8);
  backdrop-filter: blur(12px);
  border: 1px solid var(--border);
}
.milestone-meta { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1rem; }
.milestone-year { font-size: 1.5rem; font-weight: 700; }
.badge {
  font-size: 0.625rem; letter-spacing: 0.1em; text-transform: uppercase;
  padding: 0.125rem 0.5rem; border-radius: 0.25rem; border: 1px solid;
}
.badge-gold { border-color: rgba(201,162,39,0.4); color: var(--gold); }
.badge-blue { border-color: rgba(96,165,250,0.4); color: #93c5fd; }
.milestone-title { font-size: 1.5rem; font-weight: 600; margin-bottom: 0.75rem; }
.progress-bar { display: flex; gap: 0.25rem; margin-top: 1.5rem; }
.progress-seg { height: 0.25rem; flex: 1; border-radius: 999px; background: rgba(245,240,230,0.1); transition: background 0.3s; }
.progress-seg.active { background: var(--gold); }

/* Sections */
.section { position: relative; z-index: 10; padding: 6rem 0; }
.section-dark { background: var(--background); }
.section-surface { background: var(--surface); }
.section-title { font-size: clamp(1.875rem, 3vw, 2.25rem); font-weight: 700; margin-bottom: 1rem; }
.section-desc { color: rgba(245,240,230,0.5); max-width: 36rem; margin-bottom: 3rem; }

/* Sectors grid */
.sectors-grid {
  display: grid; gap: 1.5rem;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}
.sector-card {
  border-radius: 1rem; border: 1px solid var(--border);
  background: linear-gradient(to bottom, var(--surface), var(--surface-elevated));
  overflow: hidden; transition: all 0.4s;
}
.sector-card:hover {
  border-color: rgba(201,162,39,0.5);
  box-shadow: 0 8px 40px rgba(201,162,39,0.12);
}
.sector-icon-wrap { padding: 2rem 1.5rem 0.5rem; display: flex; justify-content: center; }
.sector-icon-box {
  width: 5rem; height: 5rem; padding: 0.75rem;
  border-radius: 1rem; border: 1px solid rgba(201,162,39,0.2);
  background: linear-gradient(135deg, var(--surface-elevated), var(--surface));
}
.sector-svg { width: 100%; height: 100%; }
.sector-body { padding: 1rem 1.5rem 1.5rem; text-align: center; }
.sector-name { font-size: 1.125rem; font-weight: 600; margin-bottom: 0.5rem; }
.sector-card:hover .sector-name { color: var(--gold); }

/* Subsidiaries */
.subs-list { display: flex; flex-direction: column; gap: 1rem; }
.sub-card {
  display: flex; flex-wrap: wrap; align-items: center; gap: 1.5rem;
  padding: 1.5rem; border-radius: 0.75rem;
  border: 1px solid var(--border); background: var(--surface-elevated);
  transition: border-color 0.3s;
}
.sub-card:hover { border-color: rgba(201,162,39,0.4); }
.sub-num { font-size: 1.875rem; font-weight: 700; color: rgba(201,162,39,0.3); width: 3rem; }
.sub-info { flex: 1; min-width: 200px; }
.sub-name { font-size: 1.25rem; font-weight: 600; margin-bottom: 0.25rem; }
.sub-loc {
  font-size: 0.75rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--gold); border: 1px solid rgba(201,162,39,0.3);
  border-radius: 999px; padding: 0.375rem 1rem;
}

/* Footer */
.site-footer {
  position: relative; z-index: 10;
  border-top: 1px solid var(--border);
  background: var(--surface); padding: 4rem 0;
}
.footer-grid {
  display: grid; gap: 3rem;
}
@media (min-width: 768px) { .footer-grid { grid-template-columns: repeat(3, 1fr); } }
.footer-heading {
  font-size: 0.75rem; letter-spacing: 0.15em; text-transform: uppercase;
  color: var(--gold); margin-bottom: 1rem;
}
.footer-copy {
  margin-top: 3rem; padding-top: 2rem;
  border-top: 1px solid var(--border);
  text-align: center; font-size: 0.75rem; color: rgba(245,240,230,0.4);
}

/* Admin */
.admin-page { min-height: 100vh; background: var(--background); }
.admin-header {
  border-bottom: 1px solid var(--border); background: var(--surface);
  padding: 1rem 1.5rem; display: flex; justify-content: space-between; align-items: center;
}
.admin-body { max-width: 64rem; margin: 0 auto; padding: 2rem 1.5rem; }
.admin-tabs { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 2rem; }
.tab-btn {
  padding: 0.5rem 1rem; font-size: 0.875rem; border-radius: 0.5rem;
  border: 1px solid var(--border); background: transparent;
  color: rgba(245,240,230,0.6); cursor: pointer;
}
.tab-btn.active { border-color: var(--gold); background: rgba(201,162,39,0.1); color: var(--gold); }
.admin-card {
  border: 1px solid var(--border); border-radius: 0.5rem;
  padding: 1rem; margin-bottom: 1rem;
}
.form-label {
  display: block; font-size: 0.75rem; text-transform: uppercase;
  letter-spacing: 0.05em; color: rgba(245,240,230,0.5); margin-bottom: 0.5rem;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0.5rem; margin-bottom: 1rem; }
.form-input {
  width: 100%; padding: 0.5rem 0.75rem; font-size: 0.875rem;
  background: var(--surface); border: 1px solid var(--border);
  border-radius: 0.25rem; color: var(--foreground);
}
.form-input:focus { outline: none; border-color: var(--gold); }
.btn-primary {
  padding: 0.625rem 1.5rem; background: var(--gold); color: #000;
  font-weight: 600; border: none; border-radius: 0.5rem; cursor: pointer;
}
.btn-primary:hover { background: var(--gold-light); }
.btn-danger { font-size: 0.75rem; color: #f87171; background: none; border: none; cursor: pointer; }
.btn-link { font-size: 0.875rem; color: var(--gold); background: none; border: none; cursor: pointer; }
.login-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1.5rem; }
.login-box {
  width: 100%; max-width: 24rem; padding: 2rem;
  border-radius: 1rem; border: 1px solid var(--border); background: var(--surface);
}
.login-title { text-align: center; font-size: 1.5rem; font-weight: 700; margin-bottom: 0.5rem; }
.login-sub { text-align: center; font-size: 0.875rem; color: rgba(245,240,230,0.5); margin-bottom: 1.5rem; }
.error-msg { color: #f87171; font-size: 0.875rem; text-align: center; margin-bottom: 1rem; }
.success-msg { color: #4ade80; font-size: 0.875rem; }

::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: var(--surface); }
::-webkit-scrollbar-thumb { background: var(--gold-dark); border-radius: 4px; }

.hidden { display: none !important; }
