/* ==========================================================================
   ProTech Royal Blue & Brushed Silver Corporate Luxury Design System (2026)
   Aesthetic: Executive Sapphire Blue, Deep Royal Navy & Brushed Platinum Silver
   Spacious Architectural Minimalism & Guaranteed WCAG AAA Button Contrast
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Cairo:wght@400;500;600;700;800;900&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

@layer base, theme, components, utilities;

@layer theme {
  :root {
    /* Color Space Interpolation Tokens (modern-web-guidance: visual-effects) */
    --in-oklab: ;
    --in-oklch: ;

    /* Royal Sapphire & Deep Navy Tokens */
    --navy-950: #061022;
    --navy-900: #0a1936;
    --navy-800: #0f2957;
    --navy-700: #163a78;

    --royal-700: #1e40af;
    --royal-600: #1d4ed8;
    --royal-500: #2563eb;
    --royal-400: #3b82f6;
    --royal-200: #bfdbfe;
    --royal-100: #dbeafe;
    --royal-50: #eff6ff;

    /* Brushed Metallic Silver & Platinum Tokens */
    --silver-50: #f8fafc;
    --silver-100: #f1f5f9;
    --silver-200: #e2e8f0;
    --silver-300: #cbd5e1;
    --silver-400: #94a3b8;
    --silver-500: #64748b;

    --surface-white: #ffffff;
    --text-primary: #0a1936;
    --text-secondary: #334155;
    --text-muted: #64748b;

    --border-silver: #e2e8f0;
    --border-silver-strong: #cbd5e1;
    --border-royal: rgba(37, 99, 235, 0.32);

    /* Multi-layered Realistic Soft Depth Shadows (modern-web-guidance: visual-effects) */
    --shadow-lux-sm:
      0 1px 2px rgba(6, 16, 34, 0.03),
      0 6px 16px -4px rgba(6, 16, 34, 0.05);
    --shadow-lux-md:
      0 2px 4px rgba(6, 16, 34, 0.03),
      0 14px 28px -6px rgba(10, 25, 54, 0.07),
      0 28px 56px -14px rgba(10, 25, 54, 0.05);
    --shadow-lux-xl:
      0 4px 10px rgba(6, 16, 34, 0.04),
      0 22px 44px -10px rgba(29, 78, 216, 0.12),
      0 36px 72px -18px rgba(6, 16, 34, 0.08);
    --shadow-royal-glow:
      0 10px 28px -6px rgba(29, 78, 216, 0.42),
      0 2px 8px rgba(37, 99, 235, 0.2);
  }

  @supports (background: linear-gradient(in oklab, white, black)) {
    :root {
      --in-oklab: in oklab;
      --in-oklch: in oklch;
    }
  }
}

@layer base {
  html {
    scroll-behavior: smooth;
    scroll-padding-top: 6rem;
    color-scheme: light;
  }
}

/* Unlayered Core & Component Rules so Tailwind Play CDN Preflight never overrides button/text colors */
body {
  font-family: 'Cairo', 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--silver-50);
  color: var(--text-secondary);
  direction: rtl;
  text-align: start;
  line-height: 1.7;
  overflow-x: hidden;
  position: relative;
  margin: 0;
}

h1, h2, h3, h4, th {
  text-wrap: balance;
  line-height: 1.3;
}

p, li, dd, blockquote {
  text-wrap: pretty;
  overflow-wrap: break-word;
}

.font-mono-num {
  font-family: 'Plus Jakarta Sans', monospace;
  letter-spacing: 0.02em;
}

/* Fluid Responsive Typography (modern-web-guidance: typography) */
.lux-h1 {
  font-size: clamp(1.9rem, 1.3rem + 2.2vw, 3.25rem);
  font-weight: 900;
  line-height: 1.28;
  letter-spacing: -0.01em;
}

.lux-h2 {
  font-size: clamp(1.55rem, 1.15rem + 1.4vw, 2.35rem);
  font-weight: 900;
  line-height: 1.32;
}

.lux-h3 {
  font-size: clamp(1.1rem, 1rem + 0.35vw, 1.28rem);
  font-weight: 800;
  line-height: 1.42;
}

.lux-lead {
  font-size: clamp(0.98rem, 0.92rem + 0.25vw, 1.12rem);
  line-height: 1.85;
  max-width: 64ch;
}

/* Clean Platinum-Alabaster Background */
.corporate-grid-bg {
  background-color: var(--silver-50);
}

/* Royal Sapphire & Silver Dark Section Backdrop */
.imperial-navy-section {
  background:
    radial-gradient(circle at 85% 15%, rgba(59, 130, 246, 0.22) 0%, transparent 48%),
    radial-gradient(circle at 12% 88%, rgba(203, 213, 225, 0.1) 0%, transparent 45%),
    linear-gradient(135deg var(--in-oklab), var(--navy-950) 0%, var(--navy-900) 55%, var(--navy-800) 100%);
  color: #f8fafc;
  position: relative;
  isolation: isolate;
}

/* Top Executive Ribbon */
.top-bar {
  background: linear-gradient(90deg var(--in-oklab), #050d1d 0%, #0b1e40 50%, #050d1d 100%);
  color: #e2e8f0;
  border-block-end: 1px solid rgba(203, 213, 225, 0.18);
}

/* Spacious Silver & Sapphire Luxury Card */
.corp-card {
  background-color: var(--surface-white);
  border: 1px solid var(--border-silver);
  border-radius: 1.35rem;
  box-shadow: var(--shadow-lux-sm);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              box-shadow 0.35s cubic-bezier(0.16, 1, 0.3, 1),
              border-color 0.35s ease;
  position: relative;
  overflow: hidden;
}

.corp-card:hover {
  border-color: var(--royal-400);
  box-shadow: var(--shadow-lux-xl);
  transform: translateY(-4px);
}

/* Dark Royal & Metallic Silver Card */
.imperial-card {
  background: linear-gradient(155deg var(--in-oklab), #0d2147 0%, #071229 100%);
  border: 1px solid rgba(203, 213, 225, 0.28);
  border-radius: 1.5rem;
  box-shadow:
    0 24px 48px -12px rgba(4, 10, 23, 0.5),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.16);
  color: #f8fafc;
  position: relative;
}

/* Brushed Silver & Ice Sapphire Metallic Gradient Text */
.text-silver-lux,
.text-gold-lux {
  background: linear-gradient(135deg var(--in-oklab), #ffffff 0%, #dbeafe 45%, #93c5fd 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-corp-gradient {
  background: linear-gradient(135deg var(--in-oklab), var(--navy-900) 0%, var(--royal-600) 60%, var(--royal-400) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ==========================================================================
   Executive Buttons — Guaranteed High-Contrast (Never Dark-on-Dark or Light-on-Light)
   Using min-block-size, never fixed height (modern-web-guidance: typography)
   ========================================================================== */

/* 1. Royal Sapphire Blue Button: Deep Royal Blue Background + Pure White Text */
a.btn-royal-lux,
button.btn-royal-lux,
.btn-royal-lux,
a.btn-navy-lux,
button.btn-navy-lux,
.btn-navy-lux {
  background-color: #1d4ed8 !important;
  background-image: linear-gradient(135deg var(--in-oklab), #2563eb 0%, #1d4ed8 55%, #1e3a8a 100%) !important;
  color: #ffffff !important;
  font-weight: 800;
  min-block-size: 3rem;
  padding: 0.75rem 1.75rem;
  border-radius: 0.95rem;
  border: 1px solid rgba(191, 219, 254, 0.45) !important;
  box-shadow: var(--shadow-royal-glow), inset 0 1px 0 rgba(255, 255, 255, 0.25);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  cursor: pointer;
}

a.btn-royal-lux *,
button.btn-royal-lux *,
.btn-royal-lux *,
a.btn-navy-lux *,
button.btn-navy-lux *,
.btn-navy-lux * {
  color: #ffffff !important;
}

a.btn-royal-lux:hover:not(:disabled),
button.btn-royal-lux:hover:not(:disabled),
.btn-royal-lux:hover:not(:disabled),
a.btn-navy-lux:hover:not(:disabled),
button.btn-navy-lux:hover:not(:disabled),
.btn-navy-lux:hover:not(:disabled) {
  transform: translateY(-2px);
  background-color: #1e40af !important;
  background-image: linear-gradient(135deg var(--in-oklab), #3b82f6 0%, #1d4ed8 60%, #1e3a8a 100%) !important;
  color: #ffffff !important;
  box-shadow: 0 14px 32px -6px rgba(37, 99, 235, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

/* 2. Brushed Platinum-Silver Button (for Dark Sections): Bright Silver/White Background + Deep Navy Text */
a.btn-silver-lux,
button.btn-silver-lux,
.btn-silver-lux,
a.btn-gold-lux,
button.btn-gold-lux,
.btn-gold-lux {
  background-color: #ffffff !important;
  background-image: linear-gradient(135deg var(--in-oklab), #ffffff 0%, #f1f5f9 60%, #e2e8f0 100%) !important;
  color: #0a1936 !important;
  font-weight: 800;
  min-block-size: 3rem;
  padding: 0.75rem 1.75rem;
  border-radius: 0.95rem;
  border: 1px solid #ffffff !important;
  box-shadow: 0 10px 28px -6px rgba(6, 16, 34, 0.35), inset 0 1px 0 #ffffff;
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  cursor: pointer;
}

a.btn-silver-lux *,
button.btn-silver-lux *,
.btn-silver-lux *,
a.btn-gold-lux *,
button.btn-gold-lux *,
.btn-gold-lux * {
  color: #0a1936 !important;
}

a.btn-silver-lux:hover:not(:disabled),
button.btn-silver-lux:hover:not(:disabled),
.btn-silver-lux:hover:not(:disabled),
a.btn-gold-lux:hover:not(:disabled),
button.btn-gold-lux:hover:not(:disabled),
.btn-gold-lux:hover:not(:disabled) {
  transform: translateY(-2px);
  background-color: #ffffff !important;
  background-image: none !important;
  color: #1d4ed8 !important;
  box-shadow: 0 14px 34px -6px rgba(191, 219, 254, 0.55);
}

a.btn-silver-lux:hover:not(:disabled) *,
button.btn-silver-lux:hover:not(:disabled) *,
.btn-silver-lux:hover:not(:disabled) * {
  color: #1d4ed8 !important;
}

/* Section Eyebrow Pills */
.lux-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.38rem 1.1rem;
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 800;
  background: linear-gradient(135deg var(--in-oklab), var(--royal-50) 0%, var(--silver-100) 100%);
  color: var(--royal-700) !important;
  border: 1px solid var(--royal-200);
}

.lux-eyebrow-dark {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 1.15rem;
  border-radius: 9999px;
  font-size: 0.8125rem;
  font-weight: 700;
  background: rgba(255, 255, 255, 0.1);
  color: #f1f5f9 !important;
  border: 1px solid rgba(203, 213, 225, 0.35);
  backdrop-filter: blur(8px);
}

/* Minimal Silver-Blue Divider */
.lux-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-block: 0.75rem;
}

.lux-divider::before,
.lux-divider::after {
  content: '';
  width: 3rem;
  height: 1.5px;
  background: linear-gradient(90deg, transparent, var(--royal-500), transparent);
}

.lux-divider-diamond {
  width: 0.45rem;
  height: 0.45rem;
  background-color: var(--royal-600);
  transform: rotate(45deg);
}

/* Navigation Link Underline Effect */
a.desktop-nav-link,
.desktop-nav-link {
  position: relative;
  padding-block: 0.35rem;
  color: #0a1936 !important;
  font-weight: 700;
  font-size: 0.9rem;
  transition: color 0.25s ease;
}

.desktop-nav-link::after {
  content: '';
  position: absolute;
  inset-block-end: 0;
  inset-inline-start: 0;
  width: 0;
  height: 2.5px;
  background: linear-gradient(90deg, var(--royal-600), var(--royal-400));
  border-radius: 2px;
  transition: width 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

a.desktop-nav-link:hover,
a.desktop-nav-link.active-nav,
.desktop-nav-link:hover,
.desktop-nav-link.active-nav {
  color: #1d4ed8 !important;
}

.desktop-nav-link:hover::after,
.desktop-nav-link.active-nav::after {
  width: 100%;
}

/* Portfolio Filter Buttons — Guaranteed High Contrast */
button.filter-btn,
.filter-btn {
  background-color: #ffffff !important;
  background-image: none !important;
  color: #0a1936 !important;
  border: 1.5px solid #cbd5e1 !important;
  min-block-size: 2.75rem;
  padding: 0.55rem 1.35rem;
  border-radius: 0.85rem;
  font-weight: 800;
  font-size: 0.875rem;
  transition: all 0.25s ease;
  cursor: pointer;
}

button.filter-btn:hover:not(.active),
.filter-btn:hover:not(.active) {
  border-color: #2563eb !important;
  color: #1d4ed8 !important;
  background-color: #eff6ff !important;
}

button.filter-btn.active,
.filter-btn.active {
  background-color: #1d4ed8 !important;
  background-image: linear-gradient(135deg var(--in-oklab), #2563eb 0%, #1e3a8a 100%) !important;
  color: #ffffff !important;
  border-color: #1d4ed8 !important;
  box-shadow: 0 8px 20px -4px rgba(29, 78, 216, 0.35);
}

/* Sector Switcher Tabs — Guaranteed High Contrast */
button.sector-tab,
.sector-tab {
  background-color: #ffffff !important;
  background-image: none !important;
  color: #0a1936 !important;
  border: 1.5px solid #cbd5e1 !important;
  min-block-size: 3.4rem;
  padding: 0.85rem 1.6rem;
  border-radius: 1rem;
  font-weight: 800;
  font-size: 0.95rem;
  box-shadow: var(--shadow-lux-sm);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  cursor: pointer;
}

button.sector-tab span,
.sector-tab span {
  color: #0a1936 !important;
}

button.sector-tab:hover:not(.active),
.sector-tab:hover:not(.active) {
  border-color: #2563eb !important;
  background-color: #eff6ff !important;
  color: #1d4ed8 !important;
  transform: translateY(-2px);
}

button.sector-tab:hover:not(.active) span,
.sector-tab:hover:not(.active) span {
  color: #1d4ed8 !important;
}

button.sector-tab.active,
.sector-tab.active {
  background-color: #1d4ed8 !important;
  background-image: linear-gradient(135deg var(--in-oklab), #2563eb 0%, #1e3a8a 100%) !important;
  border-color: #2563eb !important;
  color: #ffffff !important;
  box-shadow: 0 14px 28px -6px rgba(29, 78, 216, 0.38);
  transform: translateY(-2px);
}

button.sector-tab.active span,
.sector-tab.active span {
  color: #ffffff !important;
}

/* Hero Showcase Switcher Tabs — Guaranteed Crisp Light Text on Dark Background */
button.hero-tab-btn,
.hero-tab-btn {
  background-color: rgba(15, 41, 87, 0.75) !important;
  background-image: none !important;
  border: 1px solid rgba(203, 213, 225, 0.3) !important;
  color: #f1f5f9 !important;
  border-radius: 0.9rem;
  padding: 0.65rem 0.5rem;
  transition: all 0.25s ease;
  cursor: pointer;
}

button.hero-tab-btn *,
.hero-tab-btn * {
  color: #f1f5f9 !important;
}

button.hero-tab-btn:hover:not(.active),
.hero-tab-btn:hover:not(.active) {
  background-color: rgba(37, 99, 235, 0.4) !important;
  border-color: #93c5fd !important;
  color: #ffffff !important;
}

button.hero-tab-btn.active,
.hero-tab-btn.active {
  background-color: #1d4ed8 !important;
  background-image: linear-gradient(145deg, #2563eb 0%, #1e3a8a 100%) !important;
  border: 1.5px solid #93c5fd !important;
  color: #ffffff !important;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}

button.hero-tab-btn.active *,
.hero-tab-btn.active * {
  color: #ffffff !important;
}

/* Before & After Interactive Slider */
.ba-container {
  position: relative;
  overflow: hidden;
  border-radius: 1.5rem;
  user-select: none;
  touch-action: pan-y;
  box-shadow: 0 25px 55px -12px rgba(6, 16, 34, 0.5);
  border: 2px solid rgba(203, 213, 225, 0.45);
}

.ba-before-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  clip-path: polygon(0 0, var(--slider-pos, 50%) 0, var(--slider-pos, 50%) 100%, 0 100%);
  transition: clip-path 0.04s ease-out;
}

.ba-slider-handle {
  position: absolute;
  inset-block: 0;
  left: var(--slider-pos, 50%);
  width: 3px;
  background: linear-gradient(180deg, #ffffff, #60a5fa, #ffffff);
  transform: translateX(-50%);
  box-shadow: 0 0 16px rgba(59, 130, 246, 0.9);
  cursor: ew-resize;
  z-index: 20;
}

.ba-slider-button {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 46px;
  height: 46px;
  background: var(--royal-600);
  border: 2px solid #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.45);
}

/* Card Image Container & Smooth Zoom */
.portfolio-img-container {
  overflow: hidden;
  position: relative;
  border-radius: 1rem;
  background-color: var(--navy-900);
}

.portfolio-img-container img {
  transition: transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
}

.corp-card:hover .portfolio-img-container img {
  transform: scale(1.05);
}

/* Dialog Top-Layer Modal */
dialog {
  padding: 0;
  border: 1.5px solid var(--border-silver-strong);
  border-radius: 1.5rem;
  background: var(--surface-white);
  color: var(--text-primary);
  max-width: 94vw;
  width: 920px;
  box-shadow: 0 32px 70px -15px rgba(6, 16, 34, 0.55);
}

dialog::backdrop {
  background: rgba(6, 16, 34, 0.75);
  backdrop-filter: blur(8px);
}

/* FAQ Accordion */
details > summary {
  list-style: none;
}
details > summary::-webkit-details-marker {
  display: none;
}
details[open] {
  border-color: var(--royal-500);
  box-shadow: var(--shadow-lux-md);
}
details[open] summary .faq-icon {
  transform: rotate(180deg);
  color: var(--royal-600);
}

/* Floating WhatsApp Pulse */
@keyframes corp-pulse {
  0% { transform: scale(0.97); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0.6); }
  70% { transform: scale(1.03); box-shadow: 0 0 0 14px rgba(37, 99, 235, 0); }
  100% { transform: scale(0.97); box-shadow: 0 0 0 0 rgba(37, 99, 235, 0); }
}

.neon-whatsapp, .corp-whatsapp {
  animation: corp-pulse 2.5s infinite;
}

/* Scroll-Driven Entry Reveal (modern-web-guidance: scroll-entry-exit-effects) */
@media (prefers-reduced-motion: no-preference) {
  @supports ((animation-timeline: view()) and (animation-range: entry)) {
    @keyframes lux-reveal {
      from {
        opacity: 0.15;
        transform: translateY(20px);
      }
      to {
        opacity: 1;
        transform: translateY(0);
      }
    }

    .corp-card,
    .imperial-card {
      animation: lux-reveal auto ease-out backwards;
      animation-timeline: view();
      animation-range: entry 5% cover 20%;
    }
  }
}

/* Forced Colors Accessibility Fallback (modern-web-guidance: color) */
@media (forced-colors: active) {
  .corp-card,
  .imperial-card,
  .btn-royal-lux,
  .btn-silver-lux,
  .btn-gold-lux,
  .btn-navy-lux,
  .filter-btn,
  .sector-tab {
    border: 1px solid CanvasText;
  }
  .text-silver-lux,
  .text-gold-lux,
  .text-corp-gradient {
    -webkit-text-fill-color: currentColor;
    background: none;
  }
}
