/* ===================================================
   BCK Engineering — Main Stylesheet
   =================================================== */

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

:root {
  --bg:        #0e0e0e;
  --surface:   #1a1a1a;
  --border:    #2a2a2a;
  --accent:    #4a9eff;
  --accent-dim:#1e5fa0;
  --text:      #e8e8e8;
  --muted:     #888888;
  --danger:    #ff6b4a;

  --font-sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;
  --font-mono: 'Courier New', Courier, monospace;

  --max-w: 960px;
  --nav-h: 64px;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

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

a:hover {
  text-decoration: underline;
}

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

/* --- Layout --------------------------------------- */
.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

main {
  flex: 1;
}

/* --- Navigation ----------------------------------- */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(14, 14, 14, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-logo {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: bold;
  color: var(--text);
  letter-spacing: 0.05em;
  text-decoration: none;
}

.nav-logo:hover {
  color: var(--accent);
  text-decoration: none;
}

.nav-logo span {
  color: var(--accent);
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 32px;
}

.nav-links a {
  color: var(--muted);
  font-size: 0.9rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: color 0.2s;
}

.nav-links a:hover,
.nav-links a.active {
  color: var(--text);
}

/* --- Hero ----------------------------------------- */
.hero {
  padding: 100px 24px 80px;
  text-align: center;
  border-bottom: 1px solid var(--border);
}

.hero-logo {
  font-family: var(--font-mono);
  font-size: clamp(2rem, 6vw, 3.5rem);
  font-weight: bold;
  letter-spacing: 0.06em;
  color: var(--text);
  margin-bottom: 8px;
}

.hero-logo span {
  color: var(--accent);
}

.hero-tagline {
  font-size: clamp(0.95rem, 2.5vw, 1.15rem);
  color: var(--muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 32px;
}

.hero-description {
  max-width: 560px;
  margin: 0 auto 40px;
  font-size: 1.05rem;
  color: var(--text);
  line-height: 1.7;
}

.btn {
  display: inline-block;
  padding: 12px 28px;
  border: 1px solid var(--accent);
  color: var(--accent);
  font-size: 0.9rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background 0.2s, color 0.2s;
}

.btn:hover {
  background: var(--accent);
  color: var(--bg);
  text-decoration: none;
}

/* --- Section base --------------------------------- */
.section {
  padding: 72px 24px;
}

.section + .section {
  border-top: 1px solid var(--border);
}

.section-label {
  font-size: 0.75rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 12px;
}

.section-title {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 600;
  color: var(--text);
  margin-bottom: 16px;
}

.section-subtitle {
  font-size: 1rem;
  color: var(--muted);
  max-width: 560px;
  line-height: 1.7;
  margin-bottom: 48px;
}

/* --- Services grid (home overview) ---------------- */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1px;
  background: var(--border);
  border: 1px solid var(--border);
}

.service-card {
  background: var(--surface);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: background 0.2s;
}

.service-card:hover {
  background: #1f1f1f;
}

.service-icon {
  font-size: 1.6rem;
  line-height: 1;
}

.service-card h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text);
  letter-spacing: 0.02em;
}

.service-card p {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.65;
  flex: 1;
}

/* --- Services detail (services.html) -------------- */
.service-detail {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 72px 24px;
}

.service-item {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 0 24px;
  padding: 40px 0;
  border-bottom: 1px solid var(--border);
}

.service-item:first-of-type {
  border-top: 1px solid var(--border);
}

.service-item-icon {
  font-size: 2rem;
  padding-top: 4px;
}

.service-item h2 {
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 10px;
}

.service-item p {
  color: var(--muted);
  line-height: 1.75;
  font-size: 0.95rem;
}

/* --- Page header (inner pages) -------------------- */
.page-header {
  padding: 64px 24px 48px;
  border-bottom: 1px solid var(--border);
}

.page-header .container {
  padding: 0;
}

.page-header .section-label {
  margin-bottom: 8px;
}

.page-header h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 600;
  color: var(--text);
  margin-bottom: 12px;
}

.page-header p {
  font-size: 1rem;
  color: var(--muted);
  max-width: 520px;
  line-height: 1.7;
}

/* --- About ---------------------------------------- */
.about-body {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 72px 24px;
}

.about-body p {
  font-size: 1rem;
  color: var(--muted);
  line-height: 1.8;
  max-width: 660px;
  margin-bottom: 24px;
}

.about-body p:last-child {
  margin-bottom: 0;
}

.about-body strong {
  color: var(--text);
}

.about-list {
  list-style: none;
  margin: 8px 0 24px 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.about-list li {
  font-size: 0.95rem;
  color: var(--muted);
  padding-left: 20px;
  position: relative;
  line-height: 1.6;
}

.about-list li::before {
  content: '—';
  position: absolute;
  left: 0;
  color: var(--accent);
}

/* --- Contact -------------------------------------- */
.contact-body {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 72px 24px;
}

.contact-email {
  display: inline-block;
  font-family: var(--font-mono);
  font-size: clamp(1.1rem, 3vw, 1.5rem);
  color: var(--accent);
  border-bottom: 1px solid var(--accent-dim);
  padding-bottom: 2px;
  margin-bottom: 24px;
  text-decoration: none;
  transition: border-color 0.2s, color 0.2s;
}

.contact-email:hover {
  color: #7ab8ff;
  border-color: #7ab8ff;
  text-decoration: none;
}

.contact-body p {
  font-size: 0.95rem;
  color: var(--muted);
  max-width: 480px;
  line-height: 1.75;
  margin-bottom: 16px;
}

.contact-meta {
  margin-top: 40px;
  padding-top: 32px;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--muted);
}

/* --- Footer --------------------------------------- */
footer {
  border-top: 1px solid var(--border);
  padding: 32px 24px;
}

.footer-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-logo {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--muted);
  letter-spacing: 0.05em;
}

.footer-logo span {
  color: var(--accent);
}

.footer-links {
  list-style: none;
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}

.footer-links a {
  font-size: 0.82rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-copy {
  font-size: 0.8rem;
  color: var(--muted);
  opacity: 0.5;
}

/* --- Responsive ----------------------------------- */
@media (max-width: 640px) {
  .nav-links {
    gap: 20px;
  }

  .nav-links a {
    font-size: 0.8rem;
  }

  .hero {
    padding: 64px 24px 56px;
  }

  .services-grid {
    grid-template-columns: 1fr;
  }

  .service-item {
    grid-template-columns: 1fr;
  }

  .service-item-icon {
    margin-bottom: -8px;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
