/* --------------------------------------------------
   CSS Reset & Variables (Dark Tech Engineering Minimal)
--------------------------------------------------- */
:root {
  --bg-primary: #0F172A;
  --bg-card: #1E293B;
  --bg-card-glass: rgba(30, 41, 59, 0.75);
  --bg-darker: #0B1120;
  --border-color: rgba(148, 163, 184, 0.15);
  --border-color-glow: rgba(6, 182, 212, 0.35);
  
  --accent-cyan: #06B6D4;
  --accent-cyan-hover: #22d3ee;
  --accent-cyan-glow: rgba(6, 182, 212, 0.25);
  --accent-emerald: #10B981;
  
  --text-primary: #F8FAFC;
  --text-secondary: #94A3B8;
  --text-muted: #64748B;
  
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-pill: 9999px;
  
  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.25);
  --shadow-md: 0 10px 25px rgba(0, 0, 0, 0.35);
  --shadow-glow: 0 0 20px rgba(6, 182, 212, 0.2);
  
  --transition: 0.2s ease-in-out;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  background-color: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  padding-bottom: 76px; /* space for mobile sticky bar */
}

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

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

/* --------------------------------------------------
   Typography & Utility Classes
--------------------------------------------------- */
.code-font {
  font-family: var(--font-mono);
}

.text-cyan {
  color: var(--accent-cyan);
}

.text-gradient {
  background: linear-gradient(135deg, #F8FAFC 0%, var(--accent-cyan) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.text-center {
  text-align: center;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 16px;
}

.section-wrapper {
  padding: 60px 0;
  position: relative;
}

.section-alt {
  background-color: var(--bg-darker);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.section-header {
  margin-bottom: 40px;
}

.section-title {
  font-size: clamp(1.6rem, 4vw, 2.35rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin: 12px 0 16px 0;
  line-height: 1.25;
  word-break: break-word;
}

.section-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 680px;
  margin: 0 auto;
  line-height: 1.6;
}

.pill-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 4px 14px;
  border-radius: var(--radius-pill);
  background: rgba(6, 182, 212, 0.1);
  border: 1px solid rgba(6, 182, 212, 0.3);
  color: var(--accent-cyan);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  max-width: 100%;
  white-space: normal;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background-color: var(--accent-emerald);
  box-shadow: 0 0 8px var(--accent-emerald);
  flex-shrink: 0;
}

/* --------------------------------------------------
   Buttons
--------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: var(--font-sans);
  font-weight: 600;
  font-size: 0.95rem;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
  text-decoration: none;
}

.btn-primary {
  background-color: var(--accent-cyan);
  color: #0B1120;
  box-shadow: 0 4px 14px rgba(6, 182, 212, 0.3);
}

.btn-primary:hover,
.btn-primary:focus-visible {
  background-color: var(--accent-cyan-hover);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(6, 182, 212, 0.45);
}

.btn-secondary {
  background-color: var(--bg-card);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background-color: #283548;
  border-color: var(--accent-cyan);
}

.btn-outline {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-outline:hover {
  border-color: var(--accent-cyan);
  color: var(--accent-cyan);
  background: rgba(6, 182, 212, 0.05);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.88rem;
  border-radius: var(--radius-sm);
}

.btn-block {
  width: 100%;
}

.btn-icon {
  width: 18px;
  height: 18px;
}

/* --------------------------------------------------
   Header & Navigation
--------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: all var(--transition);
}

.header-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-logo {
  display: inline-flex;
  align-items: center;
  font-family: var(--font-mono);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.logo-bracket {
  color: var(--accent-cyan);
  margin: 0 2px;
}

.mobile-toggle {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  width: 32px;
  height: 22px;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 101;
}

.hamburger-line {
  width: 100%;
  height: 2px;
  background-color: var(--text-primary);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.mobile-toggle.active .hamburger-line:nth-child(1) {
  transform: translateY(10px) rotate(45deg);
}
.mobile-toggle.active .hamburger-line:nth-child(2) {
  opacity: 0;
}
.mobile-toggle.active .hamburger-line:nth-child(3) {
  transform: translateY(-10px) rotate(-45deg);
}

.nav-menu {
  display: none;
  position: fixed;
  top: 60px;
  left: 0;
  width: 100%;
  height: calc(100vh - 60px);
  background: var(--bg-primary);
  flex-direction: column;
  padding: 32px 24px;
  border-top: 1px solid var(--border-color);
  overflow-y: auto;
}

.nav-menu.open {
  display: flex;
}

.nav-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 20px;
  margin-bottom: 32px;
}

.nav-link {
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-secondary);
  display: block;
  padding: 8px 0;
}

.nav-link:hover,
.nav-link:focus {
  color: var(--accent-cyan);
}

/* --------------------------------------------------
   Hero Section
--------------------------------------------------- */
.hero-section {
  padding: 36px 0 50px 0;
  position: relative;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
  align-items: center;
}

.hero-content {
  width: 100%;
  min-width: 0;
}

.hero-title {
  font-size: clamp(1.65rem, 5.5vw, 2.75rem);
  font-weight: 800;
  line-height: 1.2;
  letter-spacing: -0.03em;
  margin: 16px 0;
  overflow-wrap: break-word;
  word-break: normal;
}

.hero-subtitle {
  font-size: clamp(0.95rem, 2.5vw, 1.05rem);
  color: var(--text-secondary);
  margin-bottom: 24px;
  max-width: 540px;
  line-height: 1.6;
  overflow-wrap: break-word;
}

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.tech-badge {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  padding: 4px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-visual {
  width: 100%;
  min-width: 0;
}

/* Stylized Code IDE Window in Hero */
.ide-window {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md), 0 0 30px rgba(6, 182, 212, 0.1);
  width: 100%;
}

.ide-header {
  display: flex;
  align-items: center;
  background: #111a2e;
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-color);
  gap: 16px;
}

.ide-controls {
  display: flex;
  gap: 6px;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.dot-red { background: #ef4444; }
.dot-yellow { background: #f59e0b; }
.dot-green { background: #10b981; }

.ide-tab {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-secondary);
  background: var(--bg-card);
  padding: 3px 12px;
  border-radius: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ide-body {
  position: relative;
  background: #0d1527;
}

.hero-img {
  width: 100%;
  height: auto;
  object-fit: cover;
  display: block;
  opacity: 0.88;
}

.code-overlay {
  padding: 14px;
  background: rgba(15, 23, 42, 0.95);
  border-top: 1px solid var(--border-color);
}

.code-snippet {
  font-family: var(--font-mono);
  font-size: clamp(0.72rem, 2.5vw, 0.84rem);
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
  overflow-x: auto;
}

.code-keyword { color: var(--accent-cyan); }
.code-class { color: #facc15; }
.code-annotation { color: #e879f9; }
.code-string { color: var(--accent-emerald); }
.code-comment { color: var(--text-muted); }

/* --------------------------------------------------
   Bento Grid Section
--------------------------------------------------- */
.bento-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.bento-card {
  background: var(--bg-card-glass);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  display: flex;
  flex-direction: column;
  position: relative;
  transition: all var(--transition);
  backdrop-filter: blur(8px);
  min-width: 0;
}

.bento-card:hover {
  border-color: var(--border-color-glow);
  transform: translateY(-3px);
  box-shadow: var(--shadow-glow);
}

.card-icon-wrapper {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: rgba(6, 182, 212, 0.1);
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  flex-shrink: 0;
}

.tech-icon {
  width: 26px;
  height: 26px;
}

.card-tag {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent-emerald);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 6px;
}

.card-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 12px;
  line-height: 1.3;
}

.card-title-sm {
  font-size: 1.15rem;
}

.card-text {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 16px;
}

.feature-list {
  list-style: none;
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.feature-list li {
  font-size: 0.88rem;
  color: var(--text-secondary);
  position: relative;
  padding-left: 18px;
  line-height: 1.45;
}

.feature-list li::before {
  content: "→";
  position: absolute;
  left: 0;
  color: var(--accent-cyan);
}

.bento-visual-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.bento-img {
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  object-fit: cover;
}

.bento-css-content {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.css-showcase-box {
  background: #0B1120;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px;
  margin-bottom: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.css-code-pill {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-primary);
  background: rgba(30, 41, 59, 0.6);
  padding: 6px 10px;
  border-radius: 4px;
  border-left: 3px solid var(--accent-cyan);
  overflow-x: auto;
}

.feature-grid-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* --------------------------------------------------
   Engineering Philosophy Section
--------------------------------------------------- */
.engineering-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 36px;
  align-items: center;
}

.image-glass-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-md);
}

.feature-img {
  width: 100%;
  height: auto;
  display: block;
}

.badge-corner {
  position: absolute;
  bottom: 16px;
  left: 16px;
  background: rgba(15, 23, 42, 0.85);
  border: 1px solid var(--border-color-glow);
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.82rem;
  color: var(--accent-cyan);
  backdrop-filter: blur(6px);
}

.principles-list {
  display: flex;
  flex-direction: column;
  gap: 18px;
  margin-top: 24px;
}

.principle-item {
  display: flex;
  gap: 16px;
  background: var(--bg-card);
  padding: 18px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
}

.principle-number {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--accent-cyan);
  line-height: 1.2;
}

.principle-title {
  font-size: 1.05rem;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text-primary);
  line-height: 1.3;
}

.principle-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* --------------------------------------------------
   Contact Section & Google Maps
--------------------------------------------------- */
.contact-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
}

.contact-card {
  background: var(--bg-card-glass);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
}

.contact-helper-text {
  margin-bottom: 20px;
}

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-primary);
}

.required {
  color: var(--accent-cyan);
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  background: #111a2e;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  transition: border-color var(--transition);
}

.form-input:focus {
  outline: none;
  border-color: var(--accent-cyan);
  box-shadow: 0 0 0 3px rgba(6, 182, 212, 0.2);
}

.form-input.invalid {
  border-color: #ef4444;
}

.error-msg {
  font-size: 0.8rem;
  color: #ef4444;
  display: none;
}

.error-msg.visible {
  display: block;
}

.form-feedback {
  margin-top: 12px;
  font-size: 0.92rem;
  padding: 12px;
  border-radius: var(--radius-sm);
  display: none;
}

.form-feedback.success {
  display: block;
  background: rgba(16, 185, 129, 0.15);
  border: 1px solid var(--accent-emerald);
  color: #34d399;
}

.form-feedback.error {
  display: block;
  background: rgba(239, 68, 68, 0.15);
  border: 1px solid #ef4444;
  color: #f87171;
}

.contact-details-col {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.info-items {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 12px;
}

.info-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px;
  border-radius: var(--radius-md);
  background: rgba(15, 23, 42, 0.5);
  border: 1px solid var(--border-color);
  transition: border-color var(--transition);
}

.info-item:hover {
  border-color: var(--accent-cyan);
}

.info-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-sm);
  background: rgba(6, 182, 212, 0.12);
  color: var(--accent-cyan);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.info-icon svg {
  width: 20px;
  height: 20px;
}

.info-text {
  display: flex;
  flex-direction: column;
}

.info-label {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-family: var(--font-mono);
}

.info-value {
  font-size: 0.98rem;
  font-weight: 600;
  color: var(--text-primary);
  word-break: break-word;
}

.map-desc {
  font-size: 0.9rem;
  line-height: 1.6;
  margin-top: 8px;
  margin-bottom: 16px;
  color: var(--text-secondary);
  display: block;
  position: relative;
}

.map-wrapper {
  position: relative;
  width: 100%;
  height: 240px;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.google-map-frame {
  width: 100%;
  height: 100%;
  border: 0;
  filter: grayscale(80%) invert(90%) contrast(90%);
}

/* --------------------------------------------------
   Mobile Sticky CTA Bar
--------------------------------------------------- */
.mobile-sticky-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(15, 23, 42, 0.96);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid var(--border-color);
  display: flex;
  gap: 12px;
  padding: 10px 16px;
  z-index: 1000;
}

.mobile-sticky-bar .btn {
  flex: 1;
}

.icon-sm {
  width: 16px;
  height: 16px;
}

/* --------------------------------------------------
   Footer
--------------------------------------------------- */
.site-footer {
  background: var(--bg-darker);
  border-top: 1px solid var(--border-color);
  padding: 48px 0 36px 0;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 24px;
}

.footer-tagline {
  font-size: 0.88rem;
  color: var(--text-secondary);
  margin-top: 8px;
}

.footer-nav {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-nav a {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.footer-nav a:hover {
  color: var(--accent-cyan);
}

.footer-bottom {
  font-size: 0.82rem;
  color: var(--text-muted);
  border-top: 1px solid rgba(148, 163, 184, 0.08);
  width: 100%;
  padding-top: 20px;
}

/* --------------------------------------------------
   Media Queries & Responsive Enhancements
--------------------------------------------------- */
@media (min-width: 768px) {
  .container {
    padding: 0 24px;
  }

  .section-wrapper {
    padding: 90px 0;
  }

  .hero-section {
    padding: 60px 0 80px 0;
  }

  .section-title {
    font-size: 2.25rem;
  }

  .hero-title {
    font-size: 2.85rem;
  }

  .bento-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .bento-card-wide {
    grid-column: span 2;
  }

  .bento-visual-content {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    align-items: center;
    gap: 32px;
  }

  .bento-css-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 32px;
  }

  .feature-grid-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .contact-grid {
    grid-template-columns: 1.1fr 0.9fr;
  }

  .footer-content {
    flex-direction: row;
    justify-content: space-between;
    text-align: left;
  }

  .footer-bottom {
    text-align: center;
  }
}

@media (min-width: 992px) {
  body {
    padding-bottom: 0;
  }

  .mobile-toggle {
    display: none;
  }

  .nav-menu {
    display: flex;
    position: static;
    width: auto;
    height: auto;
    background: transparent;
    flex-direction: row;
    padding: 0;
    border-top: none;
    align-items: center;
    gap: 32px;
  }

  .nav-list {
    flex-direction: row;
    gap: 28px;
    margin-bottom: 0;
  }

  .nav-link {
    font-size: 0.95rem;
    padding: 4px 0;
  }

  .hero-section {
    padding: 80px 0 100px 0;
  }

  .hero-grid {
    grid-template-columns: 1.1fr 0.9fr;
    gap: 56px;
  }

  .engineering-grid {
    grid-template-columns: 1fr 1.1fr;
    gap: 56px;
  }

  .mobile-sticky-bar {
    display: none;
  }

  .site-footer {
    padding: 56px 0 40px 0;
  }
}