:root {
  --ink: #1c1917;
  --muted: #78716c;
  --blue: #2563eb;
  --blue-dark: #1d4ed8;
  --blue-light: rgba(37, 99, 235, 0.08);
  --yellow: #f59e0b;
  --yellow-light: rgba(245, 158, 11, 0.12);
  --paper: #fafaf9;
  --warm: #fefce8;
  --line: #e7e5e4;
  --card-bg: rgba(255, 255, 255, 0.88);
  --shadow-sm: 0 4px 16px rgba(28, 25, 23, 0.06);
  --shadow: 0 12px 48px rgba(28, 25, 23, 0.1);
  --shadow-lg: 0 24px 72px rgba(28, 25, 23, 0.14);
  --radius: 24px;
  --radius-sm: 14px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Inter", -apple-system, sans-serif;
  color: var(--ink);
  background: var(--paper);
  background-image:
    radial-gradient(ellipse at 80% 0%, rgba(37, 99, 235, 0.06), transparent 60%),
    radial-gradient(ellipse at 20% 100%, rgba(245, 158, 11, 0.08), transparent 50%);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }

.container { width: min(1180px, calc(100% - 48px)); margin: 0 auto; }

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(250, 250, 249, 0.88);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--line);
}
.nav {
  min-height: 72px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.brand { display: flex; align-items: center; gap: 12px; font-weight: 900; font-size: 18px; }
.brand-text { letter-spacing: -0.03em; }
.mark {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  border-radius: 10px;
  background: var(--blue);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
  flex-shrink: 0;
}
.links { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; }
.links > a:not(.btn) { color: var(--muted); font-weight: 600; font-size: 15px; transition: color 0.2s; }
.links > a:not(.btn):hover { color: var(--blue); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 24px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: white;
  color: var(--ink);
  font-weight: 700;
  font-size: 15px;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s, background 0.2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn.primary {
  color: white;
  border: 0;
  background: linear-gradient(135deg, var(--blue), var(--blue-dark));
  box-shadow: 0 4px 16px rgba(37, 99, 235, 0.3);
}
.btn.primary:hover { box-shadow: 0 8px 28px rgba(37, 99, 235, 0.4); }
.btn.accent {
  color: #1c1917;
  border: 0;
  background: linear-gradient(135deg, var(--yellow), #d97706);
  box-shadow: 0 4px 16px rgba(245, 158, 11, 0.3);
}
.btn.accent:hover { box-shadow: 0 8px 28px rgba(245, 158, 11, 0.4); }
.btn.white {
  color: var(--ink);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.8);
}
.btn.white:hover { background: white; }

.hero { padding: 80px 0 48px; }
.hero-grid { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px; align-items: center; }

.label {
  display: inline-flex;
  padding: 8px 14px;
  border-radius: 999px;
  color: var(--blue);
  background: var(--blue-light);
  font-weight: 700;
  font-size: 13px;
  letter-spacing: -0.01em;
}

h1, h2, h3 { margin: 0; letter-spacing: -0.04em; line-height: 1.1; }
h1 { margin-top: 16px; font-size: clamp(40px, 6.5vw, 72px); font-weight: 900; }
h2 { font-size: clamp(30px, 3.8vw, 50px); font-weight: 900; }
h3 { font-size: 21px; font-weight: 700; }
p { color: var(--muted); line-height: 1.7; }
.lead { font-size: 18px; max-width: 640px; color: var(--muted); margin-top: 16px; }

.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.visual {
  position: relative;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card-bg);
  box-shadow: var(--shadow);
}

.card-stack { display: grid; gap: 14px; }
.floating-card {
  padding: 20px 22px;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: white;
  transform: rotate(-1.2deg);
  transition: transform 0.3s, box-shadow 0.3s;
}
.floating-card:nth-child(2) { transform: rotate(1.4deg); margin-left: 20px; background: #f0f5ff; }
.floating-card:nth-child(3) { transform: rotate(-0.6deg); margin-right: 24px; background: #fefce8; }
.floating-card:hover { transform: rotate(0deg) scale(1.01); box-shadow: var(--shadow-lg); }

.metric-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-top: 18px; }
.metric { padding: 16px; border-radius: var(--radius-sm); background: white; border: 1px solid var(--line); text-align: center; }
.metric strong { display: block; font-size: 26px; color: var(--blue); }
.metric span { font-size: 13px; color: var(--muted); }

.section { padding: 72px 0; }
.section-head { margin-bottom: 32px; }
.section-head p { max-width: 580px; margin-top: 8px; }

.grid { display: grid; gap: 22px; }
.cols-3 { grid-template-columns: repeat(3, 1fr); }
.cols-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card-bg);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s, box-shadow 0.25s;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }

.card h3 { margin-bottom: 10px; }
.card p { font-size: 15px; }

.icon { width: 48px; height: 48px; display: grid; place-items: center; margin-bottom: 16px; border-radius: var(--radius-sm); background: var(--blue-light); }

.list { list-style: none; margin-top: 10px; }
.list li { padding: 6px 0 6px 22px; position: relative; font-size: 15px; color: var(--muted); }
.list li::before { content: ""; position: absolute; left: 0; top: 14px; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }

.steps { counter-reset: step; }
.step-card { position: relative; padding-top: 56px; }
.step-number {
  position: absolute;
  top: 20px;
  left: 24px;
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--blue);
  color: white;
  font-weight: 900;
  font-size: 16px;
}

.service-card { padding-top: 24px; }
.service-icon { margin-bottom: 16px; }

.portfolio-card { padding: 0 0 24px; overflow: hidden; }
.portfolio-visual { margin-bottom: 16px; line-height: 0; }
.portfolio-card h3, .portfolio-card p, .portfolio-card .tech-tag { padding: 0 24px; }
.portfolio-card p { margin: 8px 0 12px; }
.tech-tag {
  display: inline-block;
  padding: 4px 10px;
  margin: 0 4px 4px 24px;
  border-radius: 999px;
  background: var(--blue-light);
  color: var(--blue);
  font-size: 12px;
  font-weight: 600;
}

.stat-card { text-align: center; padding: 32px 20px; }
.stat-card strong { display: block; font-size: 38px; color: var(--blue); margin-bottom: 6px; }
.stat-card span { font-size: 14px; color: var(--muted); font-weight: 600; }

.stars { color: var(--yellow); font-size: 18px; margin-bottom: 10px; letter-spacing: 2px; }
.testimonial-card p { font-style: italic; margin-bottom: 16px; }
.testimonial-card strong { display: block; font-size: 15px; }
.client-role { display: block; font-size: 13px; color: var(--muted); margin-top: 2px; }

.faq details {
  padding: 20px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--card-bg);
  transition: box-shadow 0.2s;
}
.faq details:hover { box-shadow: var(--shadow-sm); }
.faq details + details { margin-top: 12px; }
.faq summary {
  cursor: pointer;
  font-size: 17px;
  font-weight: 700;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::before {
  content: "+";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--blue-light);
  color: var(--blue);
  font-weight: 900;
  font-size: 18px;
  flex-shrink: 0;
  transition: transform 0.2s, background 0.2s;
}
.faq details[open] summary::before {
  content: "\2212";
  background: var(--blue);
  color: white;
}
.faq details p {
  margin-top: 14px;
  padding-left: 38px;
  font-size: 15px;
}

.keyword-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.keyword-cloud span {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--blue-light);
  color: var(--blue);
  font-size: 13px;
  font-weight: 500;
  transition: background 0.2s;
}
.keyword-cloud span:hover { background: rgba(37, 99, 235, 0.16); }

.cta-block {
  padding: clamp(32px, 5vw, 60px);
  border-radius: var(--radius);
  color: white;
  background: linear-gradient(135deg, #1e3a5f, var(--blue) 50%, var(--blue-dark));
  box-shadow: var(--shadow-lg);
  text-align: center;
}
.cta-block h2 { color: white; }
.cta-block p { color: rgba(255, 255, 255, 0.85); margin-top: 12px; }
.cta-block .actions { justify-content: center; }

.form { display: grid; gap: 16px; padding: 32px; }
.form h2 { margin-bottom: 4px; font-size: 26px; }
.form label { font-weight: 600; font-size: 14px; color: var(--ink); display: grid; gap: 6px; }
input, textarea, select {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: white;
  color: var(--ink);
  font: inherit;
  font-size: 15px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--blue);
  box-shadow: 0 0 0 3px var(--blue-light);
}
textarea { min-height: 120px; resize: vertical; }
.form-status {
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 600;
  display: none;
}
.form-status.success { display: block; background: #f0fdf4; color: #166534; border: 1px solid #bbf7d0; }
.form-status.error { display: block; background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }
.form-status.loading { display: block; background: var(--blue-light); color: var(--blue); border: 1px solid rgba(37,99,235,0.2); }

address { font-style: normal; display: grid; gap: 14px; margin-top: 12px; }
address p { font-size: 15px; }
address strong { color: var(--ink); font-size: 13px; text-transform: uppercase; letter-spacing: 0.04em; }
address a { color: var(--blue); font-weight: 600; }
address a:hover { text-decoration: underline; }

footer { padding: 48px 0 24px; border-top: 1px solid var(--line); background: rgba(255, 255, 255, 0.7); margin-top: 24px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 0.8fr 0.8fr 1fr; gap: 32px; margin-bottom: 24px; }
.footer-grid > div > strong { display: block; margin-bottom: 8px; font-size: 15px; }
.footer-grid p { font-size: 14px; }
.footer-links { display: grid; gap: 8px; }
.footer-links a { color: var(--muted); font-size: 14px; transition: color 0.2s; }
.footer-links a:hover { color: var(--blue); }
.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 13px;
  color: var(--muted);
}
.footer-bottom a { color: var(--blue); font-weight: 600; }
.footer-bottom a:hover { text-decoration: underline; }

.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.visible { opacity: 1; transform: translateY(0); }

@media (max-width: 940px) {
  .hero-grid, .cols-3, .cols-4, .footer-grid { grid-template-columns: 1fr; }
  .nav { flex-direction: column; align-items: flex-start; padding: 12px 0; }
  .links { width: 100%; }
  .section { padding: 48px 0; }
  .hero { padding: 48px 0 32px; }
  .metric-row { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 540px) {
  .metric-row { grid-template-columns: 1fr; }
  .links a:not(.btn) { font-size: 14px; }
}
