/*
Theme Name: KD Grinding Media
Theme URI: https://kd-grindingmedia.com
Author: Khair Al Delky Manufacturing Co.
Description: Professional B2B industrial theme for KD Grinding Media
Version: 1.0
License: Private
*/

/* ============================================
   CSS VARIABLES
   ============================================ */
:root {
  --orange: #E87722;
  --orange-dark: #C4611A;
  --dark: #111111;
  --darker: #0A0A0A;
  --white: #FFFFFF;
  --light: #F5F5F5;
  --light-2: #E8E8E8;
  --gray: #888888;
  --text: #333333;
  --font: 'Inter', 'Segoe UI', system-ui, sans-serif;
  --max: 1200px;
  --ease: all 0.3s ease;
  --shadow: 0 4px 20px rgba(0,0,0,0.12);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.22);
}

/* ============================================
   RESET
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font); color: var(--text); background: var(--white); overflow-x: hidden; line-height: 1.6; }
img { max-width: 100%; height: auto; display: block; }
a { text-decoration: none; color: inherit; transition: var(--ease); }
ul { list-style: none; }
p { margin-bottom: 1rem; }

/* ============================================
   TYPOGRAPHY
   ============================================ */
h1 { font-size: clamp(2.2rem, 5.5vw, 4.2rem); font-weight: 900; line-height: 1.05; letter-spacing: -1.5px; }
h2 { font-size: clamp(1.7rem, 4vw, 2.7rem); font-weight: 900; line-height: 1.1; letter-spacing: -0.5px; }
h3 { font-size: clamp(1.1rem, 2.5vw, 1.5rem); font-weight: 700; line-height: 1.25; }
h4 { font-size: 1.1rem; font-weight: 700; }

/* ============================================
   UTILITIES
   ============================================ */
.container { max-width: var(--max); margin: 0 auto; padding: 0 28px; }
.section-pad { padding: 90px 0; }
.text-orange { color: var(--orange); }
.text-white { color: var(--white) !important; }
.text-center { text-align: center; }
.section-label {
  font-size: 0.72rem; font-weight: 700; letter-spacing: 3.5px;
  text-transform: uppercase; color: var(--orange); display: block; margin-bottom: 10px;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn {
  display: inline-block; padding: 14px 34px; font-weight: 700;
  font-size: 0.9rem; letter-spacing: 0.4px; border: 2px solid transparent;
  cursor: pointer; transition: var(--ease); font-family: var(--font);
  white-space: nowrap;
}
.btn-orange { background: var(--orange); color: var(--white); border-color: var(--orange); }
.btn-orange:hover { background: var(--orange-dark); border-color: var(--orange-dark); color: var(--white); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(232,119,34,0.45); }
.btn-dark { background: var(--dark); color: var(--white); border-color: var(--dark); }
.btn-dark:hover { background: #2a2a2a; color: var(--white); transform: translateY(-2px); }
.btn-outline-white { background: transparent; color: var(--white); border-color: rgba(255,255,255,0.7); }
.btn-outline-white:hover { background: var(--white); color: var(--dark); }
.btn-outline-orange { background: transparent; color: var(--orange); border-color: var(--orange); }
.btn-outline-orange:hover { background: var(--orange); color: var(--white); }
.btn-row { display: flex; gap: 14px; flex-wrap: wrap; }

/* ============================================
   NAVBAR
   ============================================ */
#site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 9999;
  background: rgba(8,8,8,0.98); backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  transition: var(--ease);
}
#site-header.scrolled { box-shadow: 0 4px 30px rgba(0,0,0,0.6); }
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  max-width: var(--max); margin: 0 auto; padding: 14px 28px;
}
.nav-brand { display: flex; align-items: center; gap: 13px; }
.nav-logo-box {
  width: 50px; height: 50px; background: var(--orange); display: flex;
  align-items: center; justify-content: center; font-size: 1.25rem; font-weight: 900;
  color: var(--white); letter-spacing: -1px;
  clip-path: polygon(0 0, 80% 0, 100% 20%, 100% 100%, 20% 100%, 0 80%);
  flex-shrink: 0;
}
.nav-brand-text { display: flex; flex-direction: column; }
.nav-title { font-size: 1.05rem; font-weight: 800; color: var(--white); letter-spacing: 0.5px; }
.nav-sub { font-size: 0.6rem; color: rgba(255,255,255,0.45); text-transform: uppercase; letter-spacing: 1.5px; margin-top: 1px; }
.nav-links { display: flex; align-items: center; gap: 2px; }
.nav-links a {
  color: rgba(255,255,255,0.8); font-size: 0.855rem; font-weight: 500;
  padding: 8px 14px; position: relative; transition: var(--ease); letter-spacing: 0.2px;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: 0; left: 14px; right: 14px;
  height: 2px; background: var(--orange); transform: scaleX(0); transition: transform 0.28s ease;
}
.nav-links a:hover, .nav-links a.current { color: var(--white); }
.nav-links a:hover::after, .nav-links a.current::after { transform: scaleX(1); }
.nav-cta-btn {
  background: var(--orange) !important; color: var(--white) !important;
  padding: 9px 20px !important; margin-left: 6px; font-weight: 700 !important;
}
.nav-cta-btn::after { display: none !important; }
.nav-cta-btn:hover { background: var(--orange-dark) !important; }
.nav-toggle { display: none; flex-direction: column; gap: 5px; background: none; border: none; cursor: pointer; padding: 4px; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--white); transition: var(--ease); }

/* ============================================
   HERO (Homepage)
   ============================================ */
.hero-home {
  position: relative; min-height: 100vh; display: flex; align-items: center;
  background: var(--darker); overflow: hidden; padding-top: 80px;
}
.hero-bg {
  position: absolute; inset: 0;
  background: url('assets/images/hero-home.jpg') center/cover no-repeat,
              linear-gradient(135deg, #0a0a0a 0%, #1e1008 100%);
  filter: brightness(0.32);
}
.hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(120deg, rgba(0,0,0,0.75) 0%, rgba(232,119,34,0.08) 60%, rgba(0,0,0,0.5) 100%);
}
.hero-content {
  position: relative; z-index: 2;
  max-width: var(--max); margin: 0 auto;
  padding: 80px 28px;
}
.hero-chip {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(232,119,34,0.18); border: 1px solid rgba(232,119,34,0.4);
  color: var(--orange); font-size: 0.72rem; font-weight: 700;
  letter-spacing: 2.5px; text-transform: uppercase; padding: 7px 16px;
  margin-bottom: 28px;
}
.hero-chip::before { content: ''; display: block; width: 6px; height: 6px; background: var(--orange); border-radius: 50%; }
.hero-home h1 { color: var(--white); margin-bottom: 14px; }
.hero-home h1 .accent { color: var(--orange); display: block; }
.hero-tagline {
  font-size: clamp(1rem, 2vw, 1.3rem); color: rgba(255,255,255,0.65);
  font-style: italic; font-weight: 300; letter-spacing: 2px; margin-bottom: 44px;
}
.hero-divider { width: 60px; height: 3px; background: var(--orange); margin: 20px 0 30px; }

/* Page Hero (inner pages) */
.page-hero {
  position: relative; min-height: 58vh; display: flex; align-items: flex-end;
  background: var(--darker); overflow: hidden; padding-top: 80px;
}
.page-hero-bg {
  position: absolute; inset: 0;
  background: url('assets/images/hero-inner.jpg') center/cover no-repeat,
              linear-gradient(135deg, #0a0a0a 0%, #1a1a1a 100%);
  filter: brightness(0.22);
}
.page-hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.3) 100%);
}
.page-hero-content {
  position: relative; z-index: 2;
  max-width: var(--max); margin: 0 auto; padding: 60px 28px 70px;
  width: 100%;
}
.page-hero-content h1 { color: var(--white); margin-bottom: 18px; }
.page-hero-content p { color: rgba(255,255,255,0.75); font-size: 1.1rem; max-width: 680px; line-height: 1.75; margin: 0; }

/* ============================================
   HOME - INTRO
   ============================================ */
.intro-section { padding: 100px 0; background: var(--white); }
.intro-section h2 { color: var(--dark); margin-bottom: 24px; max-width: 820px; }
.intro-text { font-size: 1.08rem; color: #444; line-height: 1.85; max-width: 820px; }
.intro-text strong { color: var(--dark); font-weight: 700; }

/* ============================================
   HOME - PRODUCTS GRID
   ============================================ */
.products-preview { padding: 80px 0; background: var(--light); }
.products-preview .section-header { margin-bottom: 48px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.prod-card {
  background: var(--white); overflow: hidden;
  box-shadow: 0 2px 14px rgba(0,0,0,0.07);
  transition: var(--ease); border-bottom: 3px solid transparent;
}
.prod-card:hover { transform: translateY(-7px); box-shadow: var(--shadow-lg); border-bottom-color: var(--orange); }
.prod-card-img {
  width: 100%; height: 210px; object-fit: cover;
  background: linear-gradient(135deg, #1a1a1a, #2d2d2d);
  display: flex; align-items: center; justify-content: center;
  overflow: hidden;
}
.prod-card-img img { width: 100%; height: 100%; object-fit: cover; }
.prod-card-img-ph { width: 100%; height: 210px; background: linear-gradient(135deg,#1c1c1c,#2e2e2e); }
.prod-card-body { padding: 22px 24px 28px; }
.prod-card-body h3 { font-size: 1.05rem; font-weight: 800; margin-bottom: 10px; color: var(--dark); }
.prod-card-body p { font-size: 0.875rem; color: #555; line-height: 1.7; margin: 0; }

/* ============================================
   HOME - DUAL FEATURE
   ============================================ */
.dual-feature { padding: 80px 0; background: var(--white); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; }
.feat-block-img {
  width: 100%; height: 360px; object-fit: cover;
  background: linear-gradient(135deg,#1a1a1a,#333); overflow: hidden;
}
.feat-block-img img { width: 100%; height: 100%; object-fit: cover; }
.feat-block-img-ph { width: 100%; height: 360px; background: linear-gradient(135deg,#1a1a1a,#2a2a2a); }
.feat-caption { padding: 22px 0 0; }
.feat-caption h3 { font-size: 1.2rem; font-weight: 800; margin-bottom: 12px; color: var(--dark); }
.feat-caption p { font-size: 0.88rem; color: #555; line-height: 1.75; margin: 0; }

/* ============================================
   ABOUT - TWO COL
   ============================================ */
.two-col { padding: 90px 0; background: var(--white); }
.two-col.bg-light-section { background: var(--light); }
.two-col-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 72px; align-items: center; }
.two-col-grid.flip { grid-template-columns: 1.1fr 1fr; }
.two-col-grid.flip .col-img { order: 2; }
.two-col-grid.flip .col-text { order: 1; }
.col-img img { width: 100%; height: 440px; object-fit: cover; }
.col-img-ph { width: 100%; height: 440px; background: linear-gradient(135deg,#1a1a1a,#2d2d2d); }
.col-text h2 { color: var(--dark); margin-bottom: 22px; }
.col-text p { font-size: 0.95rem; color: #444; line-height: 1.82; margin-bottom: 14px; }
.col-text p:last-of-type { margin-bottom: 0; }
.col-text strong { color: var(--dark); font-weight: 700; }
.bullet-list { margin-top: 22px; }
.bullet-list li {
  font-size: 0.92rem; color: #444; line-height: 1.7;
  padding: 9px 0 9px 22px; position: relative;
  border-bottom: 1px solid var(--light-2);
}
.bullet-list li:last-child { border-bottom: none; }
.bullet-list li::before {
  content: ''; position: absolute; left: 0; top: 50%; transform: translateY(-50%);
  width: 8px; height: 8px; background: var(--orange); border-radius: 50%;
}
.bullet-list li strong { color: var(--dark); font-weight: 700; }

/* ============================================
   COMMITMENTS (3-col)
   ============================================ */
.commitments { padding: 90px 0; background: var(--light); }
.commitments .section-header { text-align: center; margin-bottom: 52px; }
.commit-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.commit-card {
  background: var(--white); padding: 36px 28px;
  border-top: 4px solid var(--orange);
  box-shadow: 0 2px 12px rgba(0,0,0,0.06);
  transition: var(--ease);
}
.commit-card:hover { transform: translateY(-5px); box-shadow: var(--shadow); }
.commit-icon {
  width: 54px; height: 54px; background: rgba(232,119,34,0.1); border-radius: 50%;
  display: flex; align-items: center; justify-content: center; margin-bottom: 20px;
}
.commit-icon svg { width: 26px; height: 26px; }
.commit-card h3 { font-size: 1.05rem; font-weight: 800; margin-bottom: 12px; color: var(--dark); }
.commit-card p { font-size: 0.875rem; color: #555; line-height: 1.75; margin: 0; }

/* ============================================
   CERTIFICATIONS BAR
   ============================================ */
.certs-bar { background: var(--white); padding: 36px 28px; border-top: 1px solid var(--light-2); border-bottom: 1px solid var(--light-2); }
.certs-inner { display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 28px; max-width: var(--max); margin: 0 auto; }
.cert-label { font-size: 0.78rem; font-weight: 700; text-transform: uppercase; letter-spacing: 1.5px; color: var(--gray); font-style: italic; }
.cert-badge {
  background: var(--light); border: 1px solid var(--light-2);
  padding: 8px 16px; text-align: center; min-width: 70px;
}
.cert-badge .cert-big { display: block; font-size: 0.95rem; font-weight: 900; color: var(--dark); }
.cert-badge .cert-sm { display: block; font-size: 0.65rem; font-weight: 600; color: var(--gray); letter-spacing: 0.5px; }

/* ============================================
   PRODUCTS PAGE
   ============================================ */
.prod-detail { padding: 90px 0; background: var(--white); }
.prod-detail:nth-of-type(even) { background: var(--light); }
.prod-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 72px; align-items: center; }
.prod-detail-grid.flip .d-img { order: 2; }
.prod-detail-grid.flip .d-content { order: 1; }
.d-img img { width: 100%; height: 460px; object-fit: cover; }
.d-img-ph { width: 100%; height: 460px; background: linear-gradient(135deg,#1a1a1a,#2d2d2d); }
.prod-badge {
  display: inline-block; background: rgba(232,119,34,0.1); color: var(--orange);
  font-size: 0.72rem; font-weight: 700; letter-spacing: 1.5px;
  text-transform: uppercase; padding: 6px 14px; margin-bottom: 16px;
  border-left: 3px solid var(--orange);
}
.d-content h2 { color: var(--dark); margin-bottom: 14px; }
.d-content .d-desc { font-size: 0.95rem; color: #555; line-height: 1.8; margin-bottom: 28px; }
.specs-table { margin-bottom: 30px; border-top: 1px solid var(--light-2); }
.spec-row { display: grid; grid-template-columns: 180px 1fr; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--light-2); font-size: 0.88rem; }
.spec-key { font-weight: 700; color: var(--dark); }
.spec-val { color: #555; }

/* ============================================
   QUALITY PAGE
   ============================================ */
.testing-section { padding: 90px 0; background: var(--white); }
.testing-section .section-header { text-align: center; margin-bottom: 54px; }
.test-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.test-card { padding: 36px 26px; background: var(--light); border-top: 4px solid var(--orange); transition: var(--ease); }
.test-card:hover { box-shadow: var(--shadow); transform: translateY(-4px); background: var(--white); }
.test-icon { width: 58px; height: 58px; background: var(--orange); border-radius: 50%; display: flex; align-items: center; justify-content: center; margin-bottom: 22px; }
.test-icon svg { width: 26px; height: 26px; stroke: var(--white); fill: none; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.test-card h3 { font-size: 1.05rem; font-weight: 800; margin-bottom: 14px; color: var(--dark); }
.test-card p { font-size: 0.875rem; color: #555; line-height: 1.75; margin: 0; }
.traceability { padding: 90px 0; background: var(--light); }
.traceability .two-col-grid { gap: 64px; }

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-section { padding: 90px 0; background: var(--white); }
.contact-grid { display: grid; grid-template-columns: 1.3fr 1fr; gap: 72px; align-items: start; }
.form-title { font-size: 1.4rem; font-weight: 800; padding-bottom: 16px; border-bottom: 3px solid var(--orange); margin-bottom: 30px; display: inline-block; color: var(--dark); }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; font-size: 0.85rem; font-weight: 600; color: var(--dark); margin-bottom: 7px; letter-spacing: 0.2px; }
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%; padding: 13px 16px; border: 1.5px solid #ddd;
  font-size: 0.92rem; font-family: var(--font); color: var(--text);
  background: var(--white); transition: var(--ease); outline: none;
  appearance: none; border-radius: 0;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { border-color: var(--orange); box-shadow: 0 0 0 3px rgba(232,119,34,0.13); }
.form-group textarea { min-height: 140px; resize: vertical; }
.form-group select { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23888' stroke-width='2' fill='none'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 40px; }
.form-submit .btn { width: 100%; padding: 15px; font-size: 0.95rem; }
.form-success { background: rgba(40,167,69,0.1); border: 1px solid rgba(40,167,69,0.3); color: #1a7a35; padding: 14px 18px; margin-bottom: 20px; font-size: 0.9rem; font-weight: 600; }
.contact-info-cards { display: flex; flex-direction: column; gap: 22px; }
.info-card { background: var(--light); padding: 28px; border-left: 4px solid var(--orange); }
.info-card h3 { font-size: 1rem; font-weight: 800; margin-bottom: 16px; color: var(--dark); }
.info-item { display: flex; align-items: flex-start; gap: 11px; margin-bottom: 10px; font-size: 0.875rem; color: #444; }
.info-item:last-child { margin-bottom: 0; }
.info-item svg { width: 15px; height: 15px; stroke: var(--orange); fill: none; stroke-width: 2; flex-shrink: 0; margin-top: 3px; }
.info-item a { color: #444; } .info-item a:hover { color: var(--orange); }

/* ============================================
   CTA SECTIONS
   ============================================ */
.cta-section { background: var(--orange); padding: 84px 28px; text-align: center; }
.cta-section h2 { color: var(--white); margin-bottom: 20px; }
.cta-section p { color: rgba(255,255,255,0.9); font-size: 1.08rem; max-width: 780px; margin: 0 auto 40px; line-height: 1.75; }
.cta-section .btn-row { justify-content: center; }

/* ============================================
   FOOTER
   ============================================ */
#site-footer { background: var(--darker); padding: 64px 0 0; }
.footer-top { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 52px; padding-bottom: 52px; border-bottom: 1px solid rgba(255,255,255,0.07); }
.ft-brand .nav-logo-box { margin-bottom: 14px; }
.ft-brand-name { font-size: 1.05rem; font-weight: 800; color: var(--white); margin-bottom: 3px; }
.ft-brand-sub { font-size: 0.62rem; color: rgba(255,255,255,0.4); text-transform: uppercase; letter-spacing: 2px; margin-bottom: 14px; }
.ft-desc { font-size: 0.84rem; color: rgba(255,255,255,0.45); line-height: 1.75; margin-bottom: 22px; }
.ft-social { display: flex; gap: 10px; }
.social-icon { width: 36px; height: 36px; background: rgba(255,255,255,0.06); border: 1px solid rgba(255,255,255,0.1); display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.6); transition: var(--ease); }
.social-icon:hover { background: var(--orange); border-color: var(--orange); color: var(--white); }
.social-icon svg { width: 15px; height: 15px; fill: currentColor; }
.ft-col h4 { font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 2.5px; color: var(--white); margin-bottom: 20px; }
.ft-links { display: flex; flex-direction: column; gap: 9px; }
.ft-links a { font-size: 0.85rem; color: rgba(255,255,255,0.48); transition: var(--ease); }
.ft-links a:hover { color: var(--orange); padding-left: 4px; }
.ft-contact-item { display: flex; align-items: flex-start; gap: 10px; margin-bottom: 11px; font-size: 0.83rem; color: rgba(255,255,255,0.48); }
.ft-contact-item svg { width: 13px; height: 13px; stroke: var(--orange); fill: none; stroke-width: 2; flex-shrink: 0; margin-top: 3px; }
.ft-contact-item a { color: rgba(255,255,255,0.48); } .ft-contact-item a:hover { color: var(--orange); }
.footer-bottom { padding: 18px 28px; text-align: center; font-size: 0.78rem; color: rgba(255,255,255,0.25); }
.footer-bottom span { color: var(--orange); }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
  .grid-3, .commit-grid, .test-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  .nav-links { display: none; position: fixed; top: 78px; left: 0; right: 0; flex-direction: column; background: rgba(8,8,8,0.99); padding: 16px; border-top: 1px solid rgba(255,255,255,0.06); gap: 2px; z-index: 9998; }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 13px 16px; display: block; }
  .nav-toggle { display: flex; }
  .grid-3, .grid-2, .commit-grid, .test-grid, .two-col-grid, .two-col-grid.flip, .prod-detail-grid, .prod-detail-grid.flip, .contact-grid, .footer-top { grid-template-columns: 1fr; gap: 32px; }
  .two-col-grid.flip .col-img, .two-col-grid.flip .col-text, .prod-detail-grid.flip .d-img, .prod-detail-grid.flip .d-content { order: unset; }
  .btn-row { flex-direction: column; align-items: flex-start; }
  .cta-section .btn-row { align-items: center; }
  .section-pad { padding: 64px 0; }
  .spec-row { grid-template-columns: 1fr; gap: 3px; }
}
@media (max-width: 540px) {
  .grid-3, .commit-grid, .test-grid { grid-template-columns: 1fr; }
}
