/*
Theme Name: DIMTech HQ
Theme URI: https://dimtechhq.com
Author: DIMTech HQ
Description: Custom corporate theme for DIMTech HQ — dark, professional parent brand.
Version: 2.0.0
License: GNU General Public License v2 or later
Text Domain: dimcorp
*/

/* ============================================================
   Theme variables — approved palette only
   ============================================================ */
:root {
  --dark-blue:   #1e2640;
  --gray-orange: #dc9750;
  --dark-gray:   #363a44;
  --white:       #ffffff;

  --bg:          #1e2640;
  --bg-alt:      #363a44;
  --surface:     #252c45;
  --surface-2:   #2a3050;
  --border:      rgba(255,255,255,.1);
  --accent:      #dc9750;
  --accent-hover:#e8a866;
  --accent-glow: rgba(220,151,80,.15);
  --text:        #ffffff;
  --muted:       rgba(255,255,255,.58);
  --radius:      10px;
  --maxw:        1180px;
  --font:        'Inter', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
#mission, #builds, #custom-software, #methodology, #portfolio, #articles { scroll-margin-top: 88px; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; transition: color .15s; }
a:hover { color: var(--accent-hover); }
img { max-width: 100%; height: auto; display: block; }

h1, h2, h3, h4 { line-height: 1.15; margin: 0 0 .5em; font-weight: 800; letter-spacing: -.5px; }
h1 { font-size: clamp(2.2rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.2rem; }
p  { margin: 0 0 1em; }

.container { max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.section    { padding: 88px 0; }
.section--alt { background: var(--bg-alt); }
.center     { text-align: center; }
.eyebrow {
  display: inline-block;
  font-size: 11px; font-weight: 700; letter-spacing: 2.5px; text-transform: uppercase;
  color: var(--accent); margin-bottom: 14px;
}
.lead { color: var(--muted); font-size: 1.1rem; max-width: 640px; margin: 0 auto 8px; }

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 24px; border-radius: 8px;
  font-size: 14px; font-weight: 700; cursor: pointer;
  border: 1.5px solid transparent; transition: all .15s; white-space: nowrap;
  text-decoration: none;
}
.btn-primary { background: var(--accent); color: var(--dark-blue); border-color: var(--accent); }
.btn-primary:hover { background: var(--accent-hover); border-color: var(--accent-hover); color: var(--dark-blue); transform: translateY(-1px); }
.btn-outline { background: transparent; border-color: var(--accent); color: var(--accent); }
.btn-outline:hover { background: var(--accent-glow); color: var(--accent-hover); }
.btn-ghost  { background: transparent; border-color: rgba(255,255,255,.2); color: var(--white); }
.btn-ghost:hover  { border-color: var(--accent); color: var(--accent); }
.btn-lg { padding: 15px 32px; font-size: 15px; }

/* ============================================================
   Header / Nav
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(30,38,64,.92); backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 72px; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; flex-shrink: 0; }
.brand-logo { height: 36px; width: auto; max-width: 140px; object-fit: contain; display: block; }
.brand-name { font-weight: 800; font-size: 16px; letter-spacing: .3px; color: var(--white); line-height: 1.1; }
.brand-name small { display: block; font-size: 9px; font-weight: 500; letter-spacing: 1.5px; color: var(--muted); text-transform: uppercase; }
.nav-links { display: flex; align-items: center; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav-links a { color: rgba(255,255,255,.8); font-size: 14px; font-weight: 500; transition: color .15s; }
.nav-links a:hover { color: var(--white); }
.nav-cta { flex-shrink: 0; }
.nav-toggle { display: none; background: none; border: none; color: var(--white); cursor: pointer; padding: 8px; }
.nav-toggle svg { width: 24px; height: 24px; }
.nav-mobile-only { display: none; }

/* ============================================================
   Hero
   ============================================================ */
.hero {
  position: relative; overflow: hidden;
  padding: 120px 0 108px;
  background:
    linear-gradient(105deg, rgba(30,38,64,.96) 0%, rgba(30,38,64,.88) 42%, rgba(54,58,68,.70) 72%, rgba(30,38,64,.60) 100%),
    var(--hero-bg, none) center/cover no-repeat,
    var(--bg);
  border-bottom: 1px solid var(--border);
}
.hero-inner { position: relative; z-index: 2; }
.hero-eyebrow-pill {
  display: inline-block;
  background: var(--accent-glow); border: 1px solid rgba(220,151,80,.3);
  color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: 2px;
  text-transform: uppercase; padding: 5px 16px; border-radius: 20px; margin-bottom: 22px;
}
.hero h1 { color: var(--white); max-width: 680px; margin-bottom: 20px; }
.hero p.lead { color: var(--muted); max-width: 540px; margin: 0 0 36px; font-size: 1.1rem; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }

/* ============================================================
   Mission
   ============================================================ */
.mission-band {
  background: var(--surface);
  border-top: 3px solid var(--accent);
  border-bottom: 1px solid var(--border);
  padding: 32px 0;
}
.mission-band h2 { color: var(--white); font-size: clamp(1.2rem, 1.6vw, 1.5rem); margin: 0; font-weight: 700; max-width: 100%; line-height: 1.5; }
.mission-band .eyebrow { color: var(--accent); margin-bottom: 10px; }

/* ============================================================
   What DIMTech HQ Builds
   ============================================================ */
.builds-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2px; margin-top: 52px; }
.build-card {
  background: var(--surface); padding: 40px 36px; position: relative; overflow: hidden;
}
.build-card:nth-child(1) { border-radius: var(--radius) 0 0 0; }
.build-card:nth-child(2) { border-radius: 0 var(--radius) 0 0; }
.build-card:nth-child(3) { border-radius: 0 0 0 var(--radius); }
.build-card:nth-child(4) { border-radius: 0 0 var(--radius) 0; }
.build-card-visual {
  height: 160px; border-radius: 8px; margin-bottom: 28px; overflow: hidden;
  background: var(--bg); border: 1px solid var(--border); display: flex; align-items: center; justify-content: center;
}
.build-card-visual svg { opacity: .35; }
.build-card-visual img { width: 100%; height: 100%; object-fit: cover; display: block; }
.build-card h3 { font-size: 1.15rem; margin-bottom: 10px; color: var(--white); }
.build-card p { color: var(--muted); font-size: 14px; line-height: 1.7; margin: 0; }
.build-num { font-size: 11px; font-weight: 700; letter-spacing: 2px; color: var(--accent); margin-bottom: 14px; }

/* ============================================================
   Custom Software
   ============================================================ */
.cs-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; margin-top: 52px; }
.cs-copy h2 { margin-bottom: 16px; }
.cs-copy p { color: var(--muted); font-size: 15px; margin-bottom: 28px; max-width: 460px; }
.cs-services {
  list-style: none; padding: 0; margin: 0 0 32px;
  display: grid; grid-template-columns: 1fr 1fr; gap: 10px 24px;
}
.cs-services li { font-size: 14px; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.cs-services li::before { content: ''; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); flex-shrink: 0; }
.cs-visual-img {
  border-radius: 14px; overflow: hidden; border: 1px solid rgba(220,151,80,.25);
}
.cs-visual-img img { width: 100%; height: auto; display: block; border-radius: 14px; }

/* ============================================================
   DIM Methodology
   ============================================================ */
.dim-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 52px; }
.dim-card {
  background: var(--surface); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 36px 30px; position: relative; overflow: hidden;
}
.dim-card::before {
  content: attr(data-letter);
  position: absolute; top: -14px; right: 16px;
  font-size: 100px; font-weight: 900; color: rgba(220,151,80,.06);
  line-height: 1; pointer-events: none;
}
.dim-num { font-size: 11px; font-weight: 700; letter-spacing: 2px; color: var(--accent); margin-bottom: 18px; }
.dim-card h3 { font-size: 1.15rem; margin-bottom: 10px; }
.dim-card p { color: var(--muted); font-size: 14px; margin: 0; line-height: 1.7; }

/* ============================================================
   Portfolio
   ============================================================ */
.section--portfolio {
  position: relative; overflow: hidden; padding: 88px 0;
  background:
    linear-gradient(rgba(30,38,64,.88) 0%, rgba(30,38,64,.82) 100%),
    var(--portfolio-bg, none) center/cover no-repeat,
    var(--bg-alt);
}
.section--portfolio .container { position: relative; z-index: 2; }
.portfolio-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 52px; }
.portfolio-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 28px 24px; display: flex; flex-direction: column;
  transition: border-color .15s, transform .15s;
}
.portfolio-card:hover { border-color: var(--accent); transform: translateY(-3px); }
.portfolio-card h3 { font-size: 1.05rem; margin-bottom: 8px; }
.portfolio-card p { color: var(--muted); font-size: 14px; flex: 1; margin: 0; line-height: 1.6; }

/* ============================================================
   Email collection
   ============================================================ */
.email-band { background: var(--surface); border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); padding: 72px 0; }
.email-band-inner { max-width: 560px; margin: 0 auto; text-align: center; }
.email-band h2 { margin-bottom: 12px; }
.email-band p { color: var(--muted); margin-bottom: 28px; }
.email-form { display: flex; gap: 10px; }
.email-form input {
  flex: 1; background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  color: var(--white); font-family: var(--font); font-size: 15px; padding: 13px 16px; outline: none;
  transition: border-color .15s;
}
.email-form input::placeholder { color: var(--muted); }
.email-form input:focus { border-color: var(--accent); }
.email-form .btn { flex-shrink: 0; }

/* ============================================================
   Articles / Feed cards
   ============================================================ */
.dc-articles-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 20px; flex-wrap: wrap; margin-bottom: 36px;
}
.dc-articles-head h2 { margin: 0; }
.dc-articles-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.dc-article-card {
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: border-color .15s, transform .15s; color: var(--white); text-decoration: none;
}
.dc-article-card:hover { border-color: var(--accent); transform: translateY(-3px); color: var(--white); }
.dc-article-thumb { aspect-ratio: 16/9; overflow: hidden; background: var(--bg); flex-shrink: 0; }
.dc-article-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.dc-article-body { padding: 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.dc-article-source { font-size: 11px; font-weight: 700; letter-spacing: 1.2px; text-transform: uppercase; color: var(--accent); }
.dc-article-card h3 { font-size: 1rem; font-weight: 700; margin: 0; line-height: 1.35; color: var(--white); }
.dc-article-card p { color: var(--muted); font-size: 14px; margin: 0; flex: 1; line-height: 1.6; }
.dc-article-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 6px; padding-top: 14px; border-top: 1px solid var(--border); }
.dc-article-date { font-size: 12px; color: var(--muted); }
.dc-article-read  { font-size: 13px; font-weight: 700; color: var(--accent); }

/* ============================================================
   Page head
   ============================================================ */
.page-head { padding: 64px 0 40px; border-bottom: 1px solid var(--border); background: var(--surface); }
.page-head h1 { margin: 0; }
.page-head .lead { margin: 10px 0 0; }

/* ============================================================
   Contact
   ============================================================ */
.contact-page-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 52px; align-items: start; }
.contact-info-col h2 { margin-bottom: 22px; }
.contact-block { margin-bottom: 28px; }
.contact-block h3 { font-size: 15px; margin-bottom: 6px; color: var(--white); }
.contact-block p { color: var(--muted); font-size: 14px; margin: 0; }
.contact-line { display: flex; align-items: center; gap: 12px; color: var(--white); font-size: 15px; margin-bottom: 12px; }
.contact-line svg { width: 18px; height: 18px; stroke: var(--accent); fill: none; flex-shrink: 0; }
.contact-line a { color: var(--white); }
.contact-line a:hover { color: var(--accent); }
.contact-hours { color: var(--muted); font-size: 14px; margin: 16px 0 0; }
.contact-checklist { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 10px; }
.contact-checklist li { font-size: 14px; color: var(--muted); display: flex; align-items: flex-start; gap: 10px; line-height: 1.5; }
.contact-checklist li::before { content: ''; width: 16px; height: 16px; border-radius: 50%; background: var(--accent-glow); border: 1.5px solid var(--accent); flex-shrink: 0; margin-top: 2px; }
.contact-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px; }
.contact-card-title { font-size: 20px; margin-bottom: 22px; }
.contact-form label { display: block; font-size: 13px; font-weight: 600; color: var(--muted); margin-bottom: 6px; }
.contact-form .field { margin-bottom: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.contact-form input,
.contact-form textarea,
.contact-form select {
  width: 100%; background: var(--bg); border: 1px solid var(--border); border-radius: 8px;
  color: var(--white); font-family: var(--font); font-size: 14px; padding: 12px 14px; outline: none;
  transition: border-color .15s;
}
.contact-form input:focus,
.contact-form textarea:focus,
.contact-form select:focus { border-color: var(--accent); }
.contact-form textarea { resize: vertical; min-height: 130px; }
.contact-form select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='none' stroke='%23ffffff60' stroke-width='1.6' d='M1 1.5l5 5 5-5'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.contact-submit { width: 100%; justify-content: center; margin-top: 6px; }
.contact-agree { font-size: 12px; color: var(--muted); margin: 14px 0 0; }
.req { color: var(--accent); }
.form-note { padding: 13px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 18px; border: 1px solid; }
.form-note--ok  { background: rgba(16,185,129,.10); border-color: rgba(16,185,129,.4); color: #10b981; }
.form-note--err { background: rgba(192,57,43,.10); border-color: rgba(192,57,43,.4); color: #e07a6f; }

/* ============================================================
   Legal / Generic pages
   ============================================================ */
.legal-content { max-width: 820px; margin: 0 auto; padding: 56px 24px 88px; }
.legal-content h2 { margin: 2em 0 .6em; font-size: 1.3rem; }
.legal-content h3 { margin: 1.5em 0 .4em; font-size: 1.05rem; color: var(--muted); }
.legal-content p, .legal-content li { color: var(--muted); font-size: 15px; line-height: 1.8; }
.legal-content ul { padding-left: 22px; margin-bottom: 1em; }
.legal-content a { color: var(--accent); }
.legal-last-updated { font-size: 13px; color: var(--muted); margin-bottom: 40px; padding-bottom: 24px; border-bottom: 1px solid var(--border); }
.page-content { max-width: 800px; margin: 0 auto; padding: 56px 24px 80px; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer { background: var(--dark-gray); border-top: 2px solid var(--accent); padding: 64px 0 0; }
.footer-top { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 48px; margin-bottom: 56px; }

.footer-brand-lockup { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer-logo { height: 44px; width: auto; display: block; flex-shrink: 0; }
.footer-brand .brand-name { font-size: 17px; margin-bottom: 0; display: block; color: var(--white); font-weight: 800; line-height: 1.1; }
.footer-brand .brand-name small { display: block; font-size: 9px; font-weight: 500; letter-spacing: 1.5px; color: var(--muted); text-transform: uppercase; margin-top: 3px; }
.footer-brand .footer-tagline { color: var(--muted); font-size: 14px; line-height: 1.7; max-width: 280px; margin-bottom: 8px; }
.footer-brand .footer-sub { color: var(--muted); font-size: 13px; line-height: 1.6; max-width: 280px; }

.footer-col h4 { font-size: 11px; font-weight: 700; letter-spacing: 2px; text-transform: uppercase; color: var(--accent); margin-bottom: 18px; }
.footer-col ul { list-style: none; padding: 0; margin: 0; }
.footer-col li { margin-bottom: 10px; }
.footer-col a { color: var(--muted); font-size: 14px; transition: color .15s; }
.footer-col a:hover { color: var(--white); }

/* Email in footer */
.footer-email-label { font-size: 13px; color: var(--muted); margin-bottom: 12px; line-height: 1.5; }
.footer-email-form form {
  display: flex; flex-direction: column; gap: 12px;
}
.footer-email-form input {
  background: var(--bg); border: 1px solid rgba(220,151,80,.35); border-radius: 6px;
  color: var(--white); font-family: var(--font); font-size: 14px; padding: 11px 14px; outline: none;
  transition: border-color .15s; width: 100%;
}
.footer-email-form input::placeholder { color: var(--muted); }
.footer-email-form input:focus { border-color: var(--accent); }
.footer-email-form .btn { justify-content: center; width: 100%; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  padding: 20px 0;
  display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px;
}
.footer-bottom p { color: var(--muted); font-size: 13px; margin: 0; }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1024px) {
  .footer-top { grid-template-columns: 1fr 1fr; gap: 36px; }
}
@media (max-width: 900px) {
  .builds-grid { grid-template-columns: 1fr; gap: 2px; }
  .build-card:nth-child(1) { border-radius: var(--radius) var(--radius) 0 0; }
  .build-card:nth-child(2) { border-radius: 0; }
  .build-card:nth-child(3) { border-radius: 0; }
  .build-card:nth-child(4) { border-radius: 0 0 var(--radius) var(--radius); }
  .dim-grid { grid-template-columns: 1fr 1fr; }
  .cs-grid { grid-template-columns: 1fr; gap: 36px; }
  .portfolio-grid { grid-template-columns: 1fr 1fr; }
  .dc-articles-grid { grid-template-columns: 1fr 1fr; }
  .contact-page-grid { grid-template-columns: 1fr; gap: 36px; }
  .email-form { flex-direction: column; }
}
@media (max-width: 640px) {
  .section { padding: 60px 0; }
  .nav-links, .nav-cta { display: none; }
  .nav-toggle { display: block; }
  .nav-links.open {
    display: flex; flex-direction: column; gap: 0;
    position: absolute; top: 72px; left: 0; right: 0;
    background: var(--surface); border-bottom: 1px solid var(--border); padding: 8px 0; z-index: 99;
  }
  .nav-links.open li { width: 100%; }
  .nav-links.open a { display: block; padding: 14px 24px; border-bottom: 1px solid var(--border); font-size: 15px; }
  .nav-links.open .nav-cta-mobile { display: list-item; }
  .dim-grid, .portfolio-grid, .dc-articles-grid { grid-template-columns: 1fr; }
  .footer-top { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; align-items: flex-start; gap: 8px; }
  .hero { padding: 72px 0 80px; }
  .hero-actions .btn { flex: 1; justify-content: center; }
  .brand-name small { display: none; }
  .nav-mobile-only { display: list-item; }
  .field-row { grid-template-columns: 1fr; }
  .mission-band { padding: 36px 0; }
  .cs-services { grid-template-columns: 1fr; }
  .cs-grid { margin-top: 0; }
  #custom-software { padding: 60px 0; }
}
