/* =========================================================
   DGTEK SOLUTIONS INC.
   ========================================================= */

:root {
  /* Color system: primary brand + neutrals + status accents */
  --primary: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #eff6ff;
  --accent: #10b981;
  --accent-light: #f0fdf4;
  --accent-border: #bbf7d0;
  --accent-dark: #166534;
  --bg: #ffffff;
  --bg-muted: #f8fafc;
  --surface: #ffffff;
  --border: #e2e8f0;
  --text: #0f172a;
  --text-muted: #64748b;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow: 0 10px 25px -5px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
  --radius: 12px;
  --radius-lg: 16px;
  --max-width: 1140px;
}

/* ---------- Reset & Base ---------- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  background-color: var(--bg);
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

h1, h2, h3, h4, h5 {
  line-height: 1.2;
  color: var(--text);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section {
  padding: 80px 0;
}

.section-muted {
  background: var(--bg-muted);
}

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 12px;
}

.section-head {
  max-width: 640px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-head h2 {
  font-size: clamp(1.8rem, 4vw, 2.5rem);
}

.section-head p {
  color: var(--text-muted);
  margin-top: 12px;
  font-size: 1.05rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  padding: 12px 24px;
  border-radius: 10px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--primary);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}

.btn-ghost:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-light);
}

/* ---------- Badges & Highlights ---------- */
.badge-promo {
  background: var(--primary);
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  padding: 4px 10px;
  border-radius: 20px;
  letter-spacing: 0.5px;
  display: inline-block;
  margin-bottom: 12px;
}

.guarantee-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--accent-light);
  border: 1px solid var(--accent-border);
  color: var(--accent-dark);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-top: 10px;
}

/* ---------- Header & Navigation ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.brand-mark {
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand small {
  display: block;
  font-size: 0.62rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text-muted);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav-links a {
  font-size: 0.95rem;
  color: var(--text-muted);
  font-weight: 500;
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: var(--primary);
}

.nav-cta {
  display: flex;
  align-items: center;
  gap: 12px;
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  font-size: 1.5rem;
  color: var(--text);
  padding: 4px;
}

/* ---------- Hero ---------- */
.hero {
  padding: 80px 0;
  background: linear-gradient(180deg, #f0f7ff 0%, #ffffff 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  gap: 48px;
  align-items: center;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.2rem);
}

.hero h1 span {
  color: var(--primary);
}

.hero p {
  color: var(--text-muted);
  font-size: 1.1rem;
  margin: 18px 0 28px;
  max-width: 520px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.hero-img-wrap {
  position: relative;
}

.hero-img-wrap img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  width: 100%;
  object-fit: cover;
}

.hero-stats {
  display: flex;
  gap: 32px;
}

.hero-stats .stat strong {
  display: block;
  font-size: 1.6rem;
  color: var(--primary);
  font-weight: 800;
}

.hero-stats .stat span {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---------- Cards & Service Grid ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  display: flex;
  flex-direction: column;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
  border-color: var(--primary);
}

.card-highlight {
  border: 2px solid var(--primary) !important;
  position: relative;
  box-shadow: 0 10px 25px -5px rgba(37, 99, 235, 0.15);
}

.card-icon {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  display: grid;
  place-items: center;
  margin-bottom: 20px;
}

.card-icon svg {
  width: 24px;
  height: 24px;
}

.card h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.card p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.card ul {
  list-style: none;
  margin-top: 20px;
}

.card li {
  font-size: 0.9rem;
  color: var(--text-muted);
  padding-left: 22px;
  position: relative;
  margin-bottom: 8px;
}

.card li::before {
  content: "✓";
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 800;
}

.price-tag {
  font-size: 2.25rem;
  font-weight: 800;
  color: var(--primary);
  margin: 12px 0 4px;
}

.price-sub {
  color: var(--text-muted);
  font-size: 0.88rem;
  margin-bottom: 16px;
}

/* ---------- Portfolio Grid ---------- */
.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}

.portfolio-card {
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.portfolio-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.portfolio-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.portfolio-body {
  padding: 20px;
}

.portfolio-body h4 {
  font-size: 1.1rem;
  margin: 6px 0 4px;
}

.portfolio-body p {
  font-size: 0.9rem;
  color: var(--text-muted);
}

/* ---------- Testimonials ---------- */
.testimonial-card {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.stars {
  color: #f59e0b;
  margin-bottom: 10px;
  font-size: 1rem;
}

.testimonial-card p {
  color: var(--text);
  font-size: 0.95rem;
  font-style: italic;
}

/* ---------- About & Why Choose Us ---------- */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.why-list {
  display: grid;
  gap: 20px;
}

.why-item {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.why-item .why-ico {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: var(--accent-light);
  color: var(--accent);
  display: grid;
  place-items: center;
}

.why-item h4 {
  font-size: 1.05rem;
  margin-bottom: 2px;
}

.why-item p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Contact Section & Form ---------- */
.contact-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 48px;
}

.contact-detail {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}

.contact-detail .ci {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: var(--primary-light);
  color: var(--primary);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.contact-detail span {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  display: block;
}

.contact-detail strong {
  font-size: 0.98rem;
}

.form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px;
  box-shadow: var(--shadow);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.field {
  margin-bottom: 16px;
}

.field label {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 6px;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 0.95rem;
  font-family: inherit;
  color: var(--text);
  background: #ffffff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15);
}

.field textarea {
  resize: vertical;
  min-height: 120px;
}

.alert {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 0.9rem;
  font-weight: 500;
}

.alert-success {
  background: var(--accent-light);
  color: var(--accent-dark);
  border: 1px solid var(--accent-border);
}

.alert-error {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

/* ---------- Popup Modal ---------- */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  padding: 20px;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  background: #ffffff;
  max-width: 480px;
  width: 100%;
  border-radius: var(--radius-lg);
  padding: 32px;
  position: relative;
  box-shadow: var(--shadow-lg);
  transform: scale(0.95);
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.modal-overlay.active .modal-card {
  transform: scale(1);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: #f1f5f9;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 18px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: background 0.2s, color 0.2s;
}

.modal-close:hover {
  background: #e2e8f0;
  color: var(--text);
}

/* ---------- Footer ---------- */
.site-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 64px 0 28px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.site-footer .brand {
  color: #ffffff;
}

.site-footer .brand small {
  color: #64748b;
}

.site-footer p {
  color: #94a3b8;
  font-size: 0.92rem;
  margin-top: 14px;
  max-width: 320px;
}

.footer-col h5 {
  color: #ffffff;
  font-size: 0.95rem;
  margin-bottom: 16px;
}

.footer-col a {
  display: block;
  color: #94a3b8;
  font-size: 0.92rem;
  margin-bottom: 10px;
  transition: color 0.2s ease;
}

.footer-col a:hover {
  color: #ffffff;
}

.footer-bottom {
  border-top: 1px solid #1e293b;
  padding-top: 24px;
  text-align: center;
  font-size: 0.85rem;
  color: #64748b;
}

/* ---------- Responsive Adjustments ---------- */
@media (max-width: 900px) {
  .hero-grid,
  .about-grid,
  .contact-grid,
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }

  .hero-img-wrap {
    order: -1;
  }
}

@media (max-width: 680px) {
  .nav-links {
    display: none;
  }

  .nav-cta .btn-ghost {
    display: none;
  }

  .nav-toggle {
    display: block;
  }

  .form-row {
    grid-template-columns: 1fr;
  }

  .section {
    padding: 56px 0;
  }

  .hero-stats {
    gap: 20px;
  }

  .modal-card {
    padding: 24px;
  }
}