/*
Theme Name: Machine Innovation v2
Description: Clean light professional theme for Machine Innovation Co.
Version: 2.0
*/

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Syne:wght@700;800&display=swap');

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: 'Inter', sans-serif; color: #1a1a1a; background: #fff; overflow-x: hidden; line-height: 1.6; }
a { text-decoration: none; color: inherit; }
ul { list-style: none; }
img { max-width: 100%; display: block; }

/* ── VARIABLES ── */
:root {
  --teal: #1a7a6e;
  --teal-hover: #15635a;
  --beige: #f7f5f0;
  --beige-dark: #ede9e1;
  --black: #0f0f0f;
  --gray: #6b7280;
  --gray-light: #e5e7eb;
  --white: #ffffff;
  --font-display: 'Syne', sans-serif;
  --font-body: 'Inter', sans-serif;
  --radius: 6px;
  --radius-lg: 16px;
  --shadow: 0 4px 24px rgba(0,0,0,0.07);
  --shadow-lg: 0 16px 48px rgba(0,0,0,0.12);
  --transition: 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ── LAYOUT ── */
.container { max-width: 1160px; margin: 0 auto; padding: 0 2rem; }
section { padding: 7rem 0; }

/* ── TYPOGRAPHY ── */
.label {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--teal);
  display: block;
  margin-bottom: 0.75rem;
}
.heading {
  font-family: var(--font-display);
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
  line-height: 1.1;
  color: var(--black);
}
.heading span { color: var(--teal); }
.subtext { color: var(--gray); font-size: 1.05rem; line-height: 1.75; margin-top: 1rem; max-width: 580px; }

/* ── BUTTONS ── */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.85rem 2rem;
  border-radius: var(--radius);
  font-size: 0.88rem; font-weight: 600; letter-spacing: 0.04em;
  transition: var(--transition); cursor: pointer; border: none;
}
.btn-dark { background: var(--black); color: #fff; }
.btn-dark:hover { background: #2a2a2a; transform: translateY(-2px); box-shadow: 0 8px 24px rgba(0,0,0,0.2); }
.btn-teal { background: var(--teal); color: #fff; }
.btn-teal:hover { background: var(--teal-hover); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(26,122,110,0.35); }
.btn-outline { background: transparent; color: var(--black); border: 1.5px solid #d1d5db; }
.btn-outline:hover { border-color: var(--black); transform: translateY(-2px); }

/* ── NAV ── */
#nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding: 1.4rem 0;
  transition: var(--transition);
}
#nav.solid {
  background: rgba(255,255,255,0.97);
  backdrop-filter: blur(16px);
  padding: 1rem 0;
  box-shadow: 0 1px 0 var(--gray-light);
}
.nav-wrap { display: flex; align-items: center; justify-content: space-between; }
.nav-logo-wrap { display: flex; align-items: center; gap: 0.6rem; }
.nav-logo-box {
  width: 38px; height: 38px;
  background: var(--teal);
  border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: white; font-family: var(--font-display); font-weight: 800; font-size: 0.9rem;
}
.nav-logo-name { font-family: var(--font-display); font-weight: 800; font-size: 0.95rem; color: var(--black); }
.nav-logo-sub { font-size: 0.65rem; color: var(--gray); margin-top: 1px; }
.nav-links-list { display: flex; align-items: center; gap: 2.5rem; }
.nav-links-list a { font-size: 0.85rem; font-weight: 500; color: var(--gray); transition: color 0.2s; }
.nav-links-list a:hover { color: var(--black); }
.nav-burger { display: none; flex-direction: column; gap: 5px; cursor: pointer; }
.nav-burger span { width: 24px; height: 2px; background: var(--black); border-radius: 2px; transition: var(--transition); }

/* Mobile nav */
#mobile-nav {
  display: none; position: fixed; inset: 0; z-index: 99;
  background: white; flex-direction: column; align-items: center; justify-content: center; gap: 2rem;
}
#mobile-nav a { font-family: var(--font-display); font-size: 2.2rem; font-weight: 800; color: var(--black); }
#mobile-nav a:hover { color: var(--teal); }

/* ── HERO ── */
#hero {
  min-height: 100vh;
  background: var(--beige);
  display: flex; align-items: center;
  padding: 0; position: relative; overflow: hidden;
}
.hero-pattern {
  position: absolute; inset: 0; pointer-events: none;
  background-image: radial-gradient(circle, #d1d5db 1px, transparent 1px);
  background-size: 32px 32px;
  opacity: 0.4;
}
.hero-gradient {
  position: absolute; bottom: 0; left: 0; right: 0; height: 200px;
  background: linear-gradient(to top, var(--beige), transparent);
  pointer-events: none;
}
.hero-inner {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 4rem; align-items: center;
  padding: 8rem 0 5rem;
  position: relative; z-index: 2;
}
.hero-tag {
  display: inline-flex; align-items: center; gap: 0.5rem;
  background: white; border: 1px solid var(--gray-light);
  border-radius: 100px; padding: 0.35rem 0.9rem;
  font-size: 0.75rem; font-weight: 600; color: var(--teal);
  margin-bottom: 1.5rem; box-shadow: var(--shadow);
  opacity: 0; animation: fadeUp 0.7s ease forwards 0.2s;
}
.hero-tag-dot { width: 6px; height: 6px; background: var(--teal); border-radius: 50%; }
.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 5.5vw, 4.8rem);
  font-weight: 800; line-height: 1.0; color: var(--black);
  opacity: 0; animation: fadeUp 0.7s ease forwards 0.4s;
}
.hero-title .accent { color: var(--teal); }
.hero-title .thin { font-weight: 300; font-family: var(--font-body); font-size: 0.45em; display: block; margin-top: 0.6em; color: var(--gray); letter-spacing: 0; line-height: 1.5; }
.hero-btns {
  display: flex; gap: 1rem; flex-wrap: wrap; margin-top: 2.5rem;
  opacity: 0; animation: fadeUp 0.7s ease forwards 0.6s;
}
.hero-stats {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 1px; background: var(--gray-light);
  border-radius: var(--radius-lg); overflow: hidden;
  margin-top: 3rem;
  opacity: 0; animation: fadeUp 0.7s ease forwards 0.8s;
}
.hero-stat {
  background: white; padding: 1.5rem 1.25rem; text-align: center;
}
.hero-stat-num {
  font-family: var(--font-display); font-size: 2.2rem; font-weight: 800;
  color: var(--black); line-height: 1;
}
.hero-stat-num span { color: var(--teal); }
.hero-stat-label { font-size: 0.72rem; color: var(--gray); margin-top: 0.3rem; }

/* Hero right — brand showcase */
.hero-right {
  display: flex; flex-direction: column; gap: 1rem;
  opacity: 0; animation: fadeLeft 0.7s ease forwards 0.9s;
}
.hero-brand-card {
  background: white;
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--gray-light);
  display: flex; align-items: center; gap: 1.25rem;
  transition: var(--transition);
  cursor: default;
}
.hero-brand-card:hover {
  transform: translateX(6px);
  box-shadow: var(--shadow-lg);
  border-color: var(--teal);
}
.hero-brand-logo-box {
  width: 52px; height: 52px; border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; font-weight: 800; font-size: 0.8rem;
  font-family: var(--font-display); color: white;
}
.smc-color { background: #c0392b; }
.keyence-color { background: #1a3a8f; }
.fuji-color { background: #e67e22; }
.hero-brand-info-name { font-weight: 700; font-size: 0.95rem; color: var(--black); }
.hero-brand-info-desc { font-size: 0.78rem; color: var(--gray); margin-top: 0.2rem; }
.hero-brand-badge {
  margin-left: auto; font-size: 0.65rem; font-weight: 600;
  background: #f0fdf4; color: var(--teal); padding: 0.25rem 0.6rem;
  border-radius: 100px; border: 1px solid #bbf7d0; white-space: nowrap;
}

/* ── TRUST BAR ── */
#trust {
  padding: 2.5rem 0;
  background: white;
  border-top: 1px solid var(--gray-light);
  border-bottom: 1px solid var(--gray-light);
}
.trust-inner { display: flex; align-items: center; gap: 3rem; flex-wrap: wrap; justify-content: center; }
.trust-item { display: flex; align-items: center; gap: 0.6rem; font-size: 0.85rem; font-weight: 500; color: var(--gray); }
.trust-item svg { color: var(--teal); flex-shrink: 0; }
.trust-divider { width: 1px; height: 24px; background: var(--gray-light); }

/* ── ABOUT ── */
#about { background: white; }
.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 5rem; align-items: center; }
.about-img-stack { position: relative; }
.about-img-main {
  border-radius: var(--radius-lg); overflow: hidden;
  height: 480px; background: var(--beige);
  position: relative;
}
.about-img-main img { width: 100%; height: 100%; object-fit: cover; }
.about-img-badge {
  position: absolute; bottom: -1.5rem; right: -1.5rem;
  background: var(--teal); color: white;
  border-radius: var(--radius-lg); padding: 1.5rem 2rem;
  box-shadow: var(--shadow-lg); text-align: center;
}
.about-img-badge-num { font-family: var(--font-display); font-size: 2.5rem; font-weight: 800; line-height: 1; }
.about-img-badge-text { font-size: 0.75rem; opacity: 0.85; margin-top: 0.3rem; }
.about-branches { display: grid; grid-template-columns: 1fr 1fr; gap: 0.75rem; margin-top: 2rem; }
.about-branch {
  display: flex; align-items: center; gap: 0.6rem;
  background: var(--beige); border-radius: var(--radius);
  padding: 0.75rem 1rem;
}
.about-branch-dot { width: 8px; height: 8px; background: var(--teal); border-radius: 50%; flex-shrink: 0; }
.about-branch-name { font-size: 0.85rem; font-weight: 600; color: var(--black); }
.about-branch-role { font-size: 0.7rem; color: var(--gray); }

/* ── SERVICES ── */
#services { background: var(--beige); }
.services-header { text-align: center; margin-bottom: 3.5rem; }
.services-header .subtext { margin: 1rem auto 0; }

.brand-tabs { display: flex; justify-content: center; gap: 0.5rem; flex-wrap: wrap; margin-bottom: 2.5rem; }
.brand-tab {
  padding: 0.6rem 1.4rem; border-radius: 100px;
  font-size: 0.82rem; font-weight: 600; cursor: pointer;
  border: 1.5px solid var(--gray-light);
  background: white; color: var(--gray);
  transition: var(--transition);
}
.brand-tab:hover { border-color: var(--teal); color: var(--teal); }
.brand-tab.active { background: var(--teal); color: white; border-color: var(--teal); }

.brand-panel { display: none; }
.brand-panel.active { display: block; animation: fadeIn 0.4s ease; }

.brand-showcase {
  background: white; border-radius: var(--radius-lg);
  overflow: hidden; box-shadow: var(--shadow);
  border: 1px solid var(--gray-light);
}
.brand-showcase-hero {
  padding: 3rem; display: grid;
  grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center;
  border-bottom: 1px solid var(--gray-light);
}
.brand-showcase-img {
  border-radius: var(--radius-lg); overflow: hidden;
  height: 220px; background: var(--beige);
  position: relative;
}
.brand-showcase-img img { width: 100%; height: 100%; object-fit: cover; }
.brand-showcase-logo-overlay {
  position: absolute; top: 1rem; left: 1rem;
  background: white; border-radius: 8px; padding: 0.5rem 0.9rem;
  font-family: var(--font-display); font-weight: 900; font-size: 1.1rem;
  box-shadow: var(--shadow);
}
.brand-showcase-title { font-family: var(--font-display); font-size: 1.5rem; font-weight: 800; color: var(--black); }
.brand-showcase-sub { color: var(--gray); font-size: 0.9rem; line-height: 1.7; margin-top: 0.75rem; }
.brand-origin { display: inline-flex; align-items: center; gap: 0.4rem; margin-top: 1rem; font-size: 0.78rem; font-weight: 600; color: var(--teal); background: #f0fdf4; padding: 0.3rem 0.8rem; border-radius: 100px; border: 1px solid #bbf7d0; }

.products-section { padding: 2.5rem 3rem; }
.products-section-title { font-size: 0.78rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gray); margin-bottom: 1.25rem; }
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 0.75rem; }
.product-pill {
  display: flex; align-items: center; gap: 0.6rem;
  background: var(--beige); border-radius: var(--radius);
  padding: 0.7rem 1rem; border: 1px solid transparent;
  transition: var(--transition); cursor: default;
}
.product-pill:hover { background: #f0fdf4; border-color: #bbf7d0; }
.product-pill-dot { width: 6px; height: 6px; background: var(--teal); border-radius: 50%; flex-shrink: 0; }
.product-pill-name { font-size: 0.82rem; font-weight: 500; color: #374151; }

/* ── WHY US ── */
#why { background: white; }
.why-header { text-align: center; margin-bottom: 3.5rem; }
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
.why-card {
  border: 1.5px solid var(--gray-light); border-radius: var(--radius-lg);
  padding: 2.5rem 2rem; transition: var(--transition); position: relative; overflow: hidden;
}
.why-card::after {
  content: ''; position: absolute; bottom: 0; left: 0; right: 0; height: 3px;
  background: var(--teal); transform: scaleX(0); transform-origin: left;
  transition: var(--transition);
}
.why-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: transparent; }
.why-card:hover::after { transform: scaleX(1); }
.why-icon {
  width: 52px; height: 52px; border-radius: 12px;
  background: var(--beige); display: flex; align-items: center;
  justify-content: center; font-size: 1.5rem; margin-bottom: 1.5rem;
  transition: var(--transition);
}
.why-card:hover .why-icon { background: #f0fdf4; }
.why-title { font-family: var(--font-display); font-size: 1.05rem; font-weight: 700; color: var(--black); margin-bottom: 0.75rem; }
.why-text { font-size: 0.88rem; color: var(--gray); line-height: 1.75; }

/* ── CLIENTS ── */
#clients { background: var(--beige); overflow: hidden; }
.clients-header { text-align: center; margin-bottom: 3.5rem; }
.ticker-wrap { position: relative; overflow: hidden; margin: 0 -2rem; }
.ticker-wrap::before, .ticker-wrap::after {
  content: ''; position: absolute; top: 0; bottom: 0; width: 180px; z-index: 2;
}
.ticker-wrap::before { left: 0; background: linear-gradient(90deg, var(--beige), transparent); }
.ticker-wrap::after { right: 0; background: linear-gradient(-90deg, var(--beige), transparent); }
.ticker { display: flex; gap: 1rem; animation: ticker 45s linear infinite; width: max-content; padding: 0.25rem 0; }
.ticker:hover { animation-play-state: paused; }
.ticker-2 { animation: ticker2 55s linear infinite; margin-top: 0.75rem; }
.client-pill {
  display: flex; align-items: center; gap: 0.5rem;
  background: white; border: 1px solid var(--gray-light);
  border-radius: 100px; padding: 0.55rem 1.2rem;
  font-size: 0.8rem; font-weight: 500; color: #374151;
  white-space: nowrap; box-shadow: 0 1px 4px rgba(0,0,0,0.05);
  transition: var(--transition);
}
.client-pill:hover { border-color: var(--teal); color: var(--teal); transform: translateY(-2px); }
.client-pill-dot { width: 5px; height: 5px; background: var(--teal); border-radius: 50%; opacity: 0.5; flex-shrink: 0; }

/* ── CONTACT ── */
#contact { background: white; }
.contact-grid { display: grid; grid-template-columns: 1fr 1.1fr; gap: 5rem; align-items: start; }
.contact-branches { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 2.5rem; }
.contact-branch {
  border: 1.5px solid var(--gray-light); border-radius: var(--radius-lg);
  padding: 1.25rem; transition: var(--transition);
}
.contact-branch:hover { border-color: var(--teal); background: #f0fdf4; }
.branch-city { font-weight: 700; font-size: 0.9rem; color: var(--black); margin-bottom: 0.3rem; }
.branch-main { font-size: 0.65rem; font-weight: 600; color: var(--teal); text-transform: uppercase; letter-spacing: 0.08em; }
.branch-phone { font-size: 0.8rem; color: var(--gray); margin-top: 0.3rem; line-height: 1.7; }
.contact-email-row { display: flex; align-items: center; gap: 0.75rem; margin-top: 1.75rem; font-size: 0.88rem; color: var(--gray); }
.contact-email-row a { color: var(--teal); font-weight: 600; }
.contact-email-row a:hover { text-decoration: underline; }

.form-card {
  background: var(--beige); border-radius: var(--radius-lg);
  padding: 2.5rem; border: 1px solid var(--beige-dark);
}
.form-card-title { font-family: var(--font-display); font-size: 1.3rem; font-weight: 800; color: var(--black); margin-bottom: 2rem; }
.fg { margin-bottom: 1.25rem; }
.fg label { display: block; font-size: 0.75rem; font-weight: 600; color: #374151; letter-spacing: 0.06em; margin-bottom: 0.45rem; text-transform: uppercase; }
.fg input, .fg textarea, .fg select {
  width: 100%; background: white; border: 1.5px solid var(--gray-light);
  border-radius: var(--radius); padding: 0.8rem 1rem;
  font-family: var(--font-body); font-size: 0.88rem; color: var(--black);
  transition: var(--transition); outline: none;
}
.fg input:focus, .fg textarea:focus, .fg select:focus { border-color: var(--teal); box-shadow: 0 0 0 3px rgba(26,122,110,0.08); }
.fg textarea { resize: vertical; min-height: 110px; }
.fg-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }

/* ── FOOTER ── */
#footer { background: var(--black); padding: 3rem 0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1.5rem; }
.footer-brand { font-family: var(--font-display); font-size: 1rem; font-weight: 800; color: white; }
.footer-brand span { color: var(--teal); }
.footer-sub { font-size: 0.75rem; color: rgba(255,255,255,0.35); margin-top: 0.25rem; }
.footer-copy { font-size: 0.78rem; color: rgba(255,255,255,0.3); }
.footer-links { display: flex; gap: 2rem; }
.footer-links a { font-size: 0.78rem; color: rgba(255,255,255,0.4); transition: color 0.2s; }
.footer-links a:hover { color: rgba(255,255,255,0.8); }

/* ── REVEAL ANIMATIONS ── */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 0.75s ease, transform 0.75s ease; }
.reveal.in { opacity: 1; transform: translateY(0); }
.reveal-left { opacity: 0; transform: translateX(-28px); transition: opacity 0.75s ease, transform 0.75s ease; }
.reveal-left.in { opacity: 1; transform: translateX(0); }
.reveal-right { opacity: 0; transform: translateX(28px); transition: opacity 0.75s ease, transform 0.75s ease; }
.reveal-right.in { opacity: 1; transform: translateX(0); }
.d1 { transition-delay: 0.1s; } .d2 { transition-delay: 0.2s; }
.d3 { transition-delay: 0.3s; } .d4 { transition-delay: 0.4s; }
.d5 { transition-delay: 0.5s; }

/* ── KEYFRAMES ── */
@keyframes fadeUp { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes fadeLeft { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: translateX(0); } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes ticker { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@keyframes ticker2 { 0% { transform: translateX(-50%); } 100% { transform: translateX(0); } }
@keyframes countUp { from { opacity: 0; } to { opacity: 1; } }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .hero-inner { grid-template-columns: 1fr; }
  .hero-right { display: none; }
  .about-grid { grid-template-columns: 1fr; gap: 3rem; }
  .contact-grid { grid-template-columns: 1fr; gap: 3rem; }
  .why-grid { grid-template-columns: 1fr 1fr; }
  .brand-showcase-hero { grid-template-columns: 1fr; }
  .brand-showcase-img { height: 180px; }
}
@media (max-width: 768px) {
  section { padding: 5rem 0; }
  .nav-links-list { display: none; }
  .nav-burger { display: flex; }
  .why-grid { grid-template-columns: 1fr; }
  .contact-branches { grid-template-columns: 1fr; }
  .fg-row { grid-template-columns: 1fr; }
  .hero-stats { grid-template-columns: 1fr 1fr 1fr; }
  .trust-divider { display: none; }
  .footer-inner { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }
}
@media (max-width: 480px) {
  .container { padding: 0 1.25rem; }
  .hero-title { font-size: 2.6rem; }
  .hero-btns { flex-direction: column; }
  .hero-stats { grid-template-columns: 1fr; gap: 0; }
  .about-branches { grid-template-columns: 1fr; }
}
