/* ==========================================================================
   HASSAN AL-NOUBANI FOR DECORATION AND ROOF TILES
   مؤسسة حسن النوباني للديكور والقرميد
   Core Stylesheet & Design Tokens
   ========================================================================== */

:root {
  /* Official Brand Palette */
  --primary-dark-brown: #38231D;
  --deep-brown: #2B1A16;
  --terracotta: #A94F2D;
  --terracotta-hover: #914124;
  --copper: #D98550;
  --copper-light: #E49F73;
  --warm-off-white: #F7F3EE;
  --pure-white: #FFFFFF;
  --warm-gray: #E5DED7;
  --warm-gray-light: #F0EAE3;
  --muted-text: #74645C;
  --dark-text: #211512;
  --border-copper: rgba(217, 133, 80, 0.28);
  --border-subtle: rgba(116, 100, 92, 0.18);
  --card-bg-light: #FFFFFF;
  --card-bg-dark: #321F1A;

  /* Typography */
  --font-arabic: 'Tajawal', 'Cairo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-latin: 'Cinzel', 'Playfair Display', Georgia, serif;

  /* Shadows */
  --shadow-sm: 0 2px 8px rgba(43, 26, 22, 0.06);
  --shadow-md: 0 6px 20px rgba(43, 26, 22, 0.10);
  --shadow-lg: 0 14px 35px rgba(43, 26, 22, 0.14);
  --shadow-glow: 0 0 25px rgba(217, 133, 80, 0.22);
  --shadow-hero: inset 0 0 100px rgba(43, 26, 22, 0.6);

  /* Transitions */
  --ease-cinematic: cubic-bezier(0.25, 1, 0.5, 1);
  --ease-smooth: cubic-bezier(0.4, 0, 0.2, 1);
  --transition-fast: 0.2s var(--ease-smooth);
  --transition-normal: 0.35s var(--ease-cinematic);
  --transition-slow: 0.8s var(--ease-cinematic);
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-full: 9999px;
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-arabic);
  font-size: 16px;
  line-height: 1.7;
  color: var(--dark-text);
  background-color: var(--warm-off-white);
  direction: rtl;
  text-align: right;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: var(--warm-off-white);
}

img, picture, video {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast), border-color var(--transition-fast);
}

button, input, textarea, select {
  font-family: inherit;
  font-size: inherit;
}

/* Container */
.container {
  width: 100%;
  max-width: 1280px;
  margin-inline: auto;
  padding-inline: 1.5rem;
}

@media (min-width: 1440px) {
  .container {
    max-width: 1360px;
  }
}

/* Typography Hierarchy */
h1, h2, h3, h4, h5, h6 {
  color: var(--primary-dark-brown);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

h1 { font-size: clamp(2.2rem, 4.5vw, 3.75rem); }
h2 { font-size: clamp(1.8rem, 3.2vw, 2.6rem); }
h3 { font-size: clamp(1.35rem, 2.2vw, 1.85rem); }
h4 { font-size: 1.25rem; }
p { color: var(--muted-text); }

.lead {
  font-size: 1.15rem;
  line-height: 1.8;
  color: #55443D;
}

/* Brand Section Eyebrow */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--terracotta);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.75rem;
  position: relative;
}

.eyebrow::before {
  content: '';
  display: inline-block;
  width: 24px;
  height: 2px;
  background: linear-gradient(90deg, var(--terracotta), var(--copper));
  border-radius: 2px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.85rem 1.85rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-normal);
  text-align: center;
  white-space: nowrap;
}

.btn:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}

.btn-primary {
  background-color: var(--terracotta);
  color: var(--pure-white);
  box-shadow: 0 4px 14px rgba(169, 79, 45, 0.3);
}

.btn-primary:hover {
  background-color: var(--terracotta-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(169, 79, 45, 0.4);
  color: var(--pure-white);
}

.btn-secondary {
  background-color: transparent;
  color: var(--pure-white);
  border-color: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(8px);
}

.btn-secondary:hover {
  background-color: rgba(255, 255, 255, 0.12);
  border-color: var(--copper);
  color: var(--copper-light);
  transform: translateY(-2px);
}

.btn-outline-dark {
  background-color: transparent;
  color: var(--primary-dark-brown);
  border-color: var(--border-copper);
}

.btn-outline-dark:hover {
  background-color: var(--primary-dark-brown);
  color: var(--pure-white);
  border-color: var(--primary-dark-brown);
  transform: translateY(-2px);
}

.btn-copper {
  background: linear-gradient(135deg, var(--terracotta), var(--copper));
  color: var(--pure-white);
  box-shadow: 0 4px 16px rgba(217, 133, 80, 0.35);
}

.btn-copper:hover {
  background: linear-gradient(135deg, var(--copper), var(--terracotta));
  transform: translateY(-2px);
  box-shadow: 0 6px 22px rgba(217, 133, 80, 0.45);
}

/* WhatsApp Buttons & Badges */
.btn-whatsapp {
  background-color: #25D366;
  color: #FFFFFF;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.35);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.35rem;
  font-weight: 700;
  border-radius: var(--radius-sm);
  transition: all var(--transition-normal);
}

.btn-whatsapp:hover {
  background-color: #1EBE5D;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.5);
}

.header-whatsapp-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.65rem 1.05rem;
  background-color: #25D366;
  color: #FFFFFF;
  border-radius: var(--radius-sm);
  font-weight: 700;
  font-size: 0.92rem;
  box-shadow: 0 4px 14px rgba(37, 211, 102, 0.3);
  transition: all var(--transition-fast);
}

.header-whatsapp-btn:hover {
  background-color: #1EBE5D;
  color: #FFFFFF;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(37, 211, 102, 0.45);
}

/* Floating WhatsApp FAB across all pages */
.floating-whatsapp {
  position: fixed;
  bottom: 2rem;
  left: 2rem;
  z-index: 1500;
  display: flex;
  align-items: center;
  gap: 0.65rem;
  background-color: #25D366;
  color: #FFFFFF;
  padding: 0.75rem 1.25rem;
  border-radius: var(--radius-full);
  box-shadow: 0 8px 25px rgba(37, 211, 102, 0.45);
  transition: all var(--transition-normal);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
}

.floating-whatsapp:hover {
  background-color: #1EBE5D;
  color: #FFFFFF;
  transform: translateY(-3px) scale(1.03);
  box-shadow: 0 12px 30px rgba(37, 211, 102, 0.6);
}

.floating-whatsapp-pulse {
  position: absolute;
  inset: 0;
  border-radius: var(--radius-full);
  background-color: #25D366;
  opacity: 0.6;
  z-index: -1;
  animation: waPulse 2.2s infinite;
}

@keyframes waPulse {
  0% { transform: scale(1); opacity: 0.7; }
  100% { transform: scale(1.35); opacity: 0; }
}

@media (max-width: 768px) {
  .floating-whatsapp {
    bottom: 1.5rem;
    left: 1.25rem;
    padding: 0.75rem;
    border-radius: 50%;
  }
  .floating-whatsapp-text {
    display: none;
  }
}

/* Header & Navigation */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background-color: rgba(43, 26, 22, 0.88);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(217, 133, 80, 0.22);
  transition: all var(--transition-normal);
}

.site-header.scrolled {
  background-color: rgba(43, 26, 22, 0.96);
  box-shadow: 0 8px 30px rgba(20, 10, 8, 0.45);
}

.header-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 84px;
}

.brand-logo-link {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
}

.header-logo-img {
  height: 58px;
  width: auto;
  border-radius: 4px;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
  transition: transform var(--transition-fast);
}

.brand-logo-link:hover .header-logo-img {
  transform: scale(1.03);
}

.brand-text-wrap {
  display: flex;
  flex-direction: column;
}

.brand-title-ar {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--pure-white);
  line-height: 1.25;
}

.brand-subtitle-en {
  font-size: 0.68rem;
  color: var(--copper-light);
  letter-spacing: 0.03em;
  font-family: var(--font-latin);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 1.75rem;
}

.nav-links {
  display: flex;
  align-items: center;
  list-style: none;
  gap: 1.75rem;
}

.nav-link {
  color: rgba(247, 243, 238, 0.85);
  font-size: 0.98rem;
  font-weight: 500;
  padding: 0.4rem 0.2rem;
  position: relative;
  transition: color var(--transition-fast);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 0;
  height: 2px;
  background-color: var(--copper);
  transition: width var(--transition-normal);
  border-radius: 2px;
}

.nav-link:hover,
.nav-link.active {
  color: var(--pure-white);
}

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

.nav-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

/* Mobile Toggle */
.mobile-nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--pure-white);
  font-size: 1.6rem;
  cursor: pointer;
  padding: 0.5rem;
}

/* Mobile Drawer */
.mobile-drawer {
  display: none;
  position: fixed;
  top: 84px;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(43, 26, 22, 0.98);
  backdrop-filter: blur(20px);
  padding: 2rem 1.5rem;
  flex-direction: column;
  gap: 1.5rem;
  z-index: 999;
  overflow-y: auto;
}

.mobile-drawer.active {
  display: flex;
}

.mobile-nav-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.mobile-nav-link {
  color: var(--warm-off-white);
  font-size: 1.2rem;
  font-weight: 600;
  display: block;
  padding: 0.6rem 0;
  border-bottom: 1px solid rgba(217, 133, 80, 0.15);
}

.mobile-nav-link:hover,
.mobile-nav-link.active {
  color: var(--copper-light);
  padding-right: 0.5rem;
}

/* Responsive Header */
@media (max-width: 1024px) {
  .main-nav {
    display: none;
  }
  .mobile-nav-toggle {
    display: block;
  }
  .header-cta-btn {
    display: none;
  }
}

/* Section Common Styling */
.section-py {
  padding-block: clamp(4.5rem, 8vw, 7.5rem);
}

.section-dark {
  background-color: var(--deep-brown);
  color: var(--warm-off-white);
}

.section-dark h2,
.section-dark h3,
.section-dark h4 {
  color: var(--pure-white);
}

.section-dark p {
  color: rgba(247, 243, 238, 0.78);
}

.section-header {
  max-width: 680px;
  margin-bottom: clamp(2.5rem, 5vw, 4rem);
}

.section-header.text-center {
  margin-inline: auto;
  text-align: center;
}

.section-header.text-center .eyebrow {
  justify-content: center;
}

.section-title {
  margin-bottom: 1rem;
}

.section-desc {
  font-size: 1.1rem;
  line-height: 1.75;
}

/* Footer */
.site-footer {
  background-color: #211310;
  color: var(--warm-off-white);
  border-top: 1px solid rgba(217, 133, 80, 0.25);
  padding-top: clamp(4rem, 6vw, 6rem);
  padding-bottom: 2rem;
  margin-top: auto;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1.2fr;
  gap: 3rem;
  margin-bottom: 4rem;
}

.footer-brand-logo {
  height: 76px;
  width: auto;
  border-radius: 6px;
  margin-bottom: 1.25rem;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.4);
}

.footer-brand-desc {
  color: rgba(247, 243, 238, 0.7);
  font-size: 0.95rem;
  line-height: 1.8;
  margin-bottom: 1.5rem;
  max-width: 380px;
}

.footer-heading {
  color: var(--pure-white);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  position: relative;
  padding-bottom: 0.6rem;
}

.footer-heading::after {
  content: '';
  position: absolute;
  bottom: 0;
  right: 0;
  width: 32px;
  height: 2px;
  background-color: var(--terracotta);
}

.footer-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.footer-list a {
  color: rgba(247, 243, 238, 0.75);
  font-size: 0.92rem;
  transition: all var(--transition-fast);
}

.footer-list a:hover {
  color: var(--copper-light);
  transform: translateX(-4px);
}

.footer-contact-item {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  color: rgba(247, 243, 238, 0.8);
  font-size: 0.92rem;
  margin-bottom: 0.9rem;
}

.footer-contact-icon {
  color: var(--copper);
  font-size: 1.1rem;
  margin-top: 0.2rem;
  flex-shrink: 0;
}

.footer-bottom {
  border-top: 1px solid rgba(217, 133, 80, 0.15);
  padding-top: 1.8rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  color: rgba(247, 243, 238, 0.6);
  font-size: 0.85rem;
}

@media (max-width: 1024px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2.5rem;
  }
}

@media (max-width: 640px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

.footer-developer-credit {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: rgba(247, 243, 238, 0.75);
  font-size: 0.88rem;
}

.footer-developer-credit a {
  color: var(--copper-light);
  font-weight: 700;
  text-decoration: none;
  transition: color var(--transition-fast), text-shadow var(--transition-fast);
}

.footer-developer-credit a:hover {
  color: var(--copper);
  text-decoration: underline;
  text-shadow: 0 0 10px rgba(217, 133, 80, 0.45);
}

.secret-lead-dot {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  color: rgba(217, 133, 80, 0.5);
  font-size: 1.25rem;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  margin-inline-end: 0.3rem;
  vertical-align: middle;
  border-radius: 50%;
  transition: all var(--transition-fast);
}

.secret-lead-dot:hover,
.secret-lead-dot:focus-visible {
  color: var(--copper-light);
  transform: scale(1.65);
  text-shadow: 0 0 12px rgba(217, 133, 80, 0.9);
  outline: none;
}
