/* ==========================================================================
   Dedico Solutions — design tokens
   ========================================================================== */

:root {
  color-scheme: light dark;

  /* color — light theme */
  --paper: #f7f9fc;
  --paper-raised: #ffffff;
  --ink: #0a1128;
  --ink-soft: #1c2749;
  --slate: #525e7a;
  --cobalt: #1b3df2;
  --cobalt-hover: #0e23a8;
  --cobalt-tint: #e8ecfe;
  --amber: #e98e0d;
  --line: #dde3ef;
  --band: #0a1128;
  --band-line: rgba(247, 249, 252, 0.14);
  --header-bg: rgba(247, 249, 252, 0.85);
  --header-bg-solid: rgba(247, 249, 252, 0.94);
  --placeholder: #9aa3ba;
  --error: #c92a2a;
  --shadow: 0 18px 44px rgba(16, 24, 64, 0.14);
  --glow-opacity: 0.5;

  /* type */
  --font-display: "Bricolage Grotesque", "Instrument Sans", sans-serif;
  --font-body: "Instrument Sans", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, monospace;

  /* rhythm */
  --container: 72rem;
  --gutter: 1.5rem;
  --radius: 0.375rem;
  --header-h: 4.25rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0a0f1e;
    --paper-raised: #111a33;
    --ink: #edf1fb;
    --ink-soft: #cfd7ec;
    --slate: #8f9ab8;
    --cobalt: #5f78ff;
    --cobalt-hover: #8296ff;
    --cobalt-tint: rgba(95, 120, 255, 0.16);
    --amber: #f09c25;
    --line: #232d4e;
    --band: #0e1836;
    --band-line: rgba(247, 249, 252, 0.12);
    --header-bg: rgba(10, 15, 30, 0.82);
    --header-bg-solid: rgba(10, 15, 30, 0.94);
    --placeholder: #667097;
    --error: #ff8585;
    --shadow: 0 18px 44px rgba(0, 0, 0, 0.5);
    --glow-opacity: 1;
  }
}

/* ==========================================================================
   Base
   ========================================================================== */

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 1rem);
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.65;
  color: var(--ink);
  background-color: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  line-height: 1.1;
  margin: 0 0 1rem;
  letter-spacing: -0.01em;
}

p {
  margin: 0 0 1rem;
}

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

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

:focus-visible {
  outline: 2px solid var(--cobalt);
  outline-offset: 3px;
  border-radius: 2px;
}

.skip-link {
  position: absolute;
  top: -3rem;
  left: 1rem;
  z-index: 100;
  padding: 0.5rem 1rem;
  background: var(--ink);
  color: var(--paper);
  border-radius: var(--radius);
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 1rem;
}

.container {
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* ==========================================================================
   Shared elements
   ========================================================================== */

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cobalt);
  margin-bottom: 1.25rem;
}

.btn {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1;
  padding: 0.9rem 1.75rem;
  border-radius: var(--radius);
  border: 1.5px solid transparent;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease,
    border-color 0.2s ease, transform 0.15s ease;
}

.btn:active {
  transform: translateY(1px);
}

.btn-primary {
  background: var(--cobalt);
  color: #ffffff;
}

.btn-primary:hover {
  background: var(--cobalt-hover);
}

.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.btn-ghost {
  color: var(--ink);
  border-color: var(--line);
  background: transparent;
}

.btn-ghost:hover {
  border-color: var(--ink);
}

.btn-outline {
  color: var(--cobalt);
  border-color: var(--cobalt);
  background: transparent;
}

.btn-outline:hover {
  background: var(--cobalt);
  color: #ffffff;
}

.btn-sm {
  padding: 0.65rem 1.25rem;
  font-size: 0.9375rem;
}

/* ==========================================================================
   Header
   ========================================================================== */

.site-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  background: var(--header-bg);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s ease, background-color 0.25s ease;
}

.site-header.is-scrolled {
  border-bottom-color: var(--line);
  background: var(--header-bg-solid);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
}

.brand-name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.2rem;
  color: var(--ink);
  letter-spacing: -0.01em;
  white-space: nowrap;
}

.brand-name-light {
  font-weight: 400;
  color: var(--slate);
}

.main-nav {
  display: none;
  gap: 2rem;
}

.main-nav a {
  color: var(--ink-soft);
  font-weight: 500;
  font-size: 0.9375rem;
  transition: color 0.2s ease;
}

.main-nav a:hover {
  color: var(--cobalt);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.header-actions .btn {
  display: none;
}

/* burger */
.menu-btn {
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 6px;
  width: 2.5rem;
  height: 2.5rem;
  padding: 0.5rem;
  background: none;
  border: none;
  cursor: pointer;
}

.menu-bar {
  display: block;
  width: 100%;
  height: 2px;
  background: var(--ink);
  border-radius: 1px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-btn[aria-expanded="true"] .menu-bar:first-child {
  transform: translateY(4px) rotate(45deg);
}

.menu-btn[aria-expanded="true"] .menu-bar:last-child {
  transform: translateY(-4px) rotate(-45deg);
}

.mobile-menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  height: calc(100vh - var(--header-h));
  height: calc(100dvh - var(--header-h));
  overflow-y: auto;
  background: var(--paper);
  border-top: 1px solid var(--line);
  padding: 2rem var(--gutter);
}

.mobile-menu nav {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1.75rem;
}

.mobile-menu .mobile-link {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--ink);
}

.mobile-menu .btn {
  font-size: 1.05rem;
  margin-top: 0.5rem;
  color: #ffffff;
}

@media (min-width: 64rem) {
  .main-nav {
    display: flex;
  }

  .header-actions .btn {
    display: inline-block;
  }

  .menu-btn {
    display: none;
  }
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  padding-top: calc(var(--header-h) + 4rem);
  padding-bottom: 5rem;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  gap: 4rem;
  align-items: center;
}

.hero-title {
  font-size: clamp(2.75rem, 7vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 1.5rem;
}

.hero-title em {
  font-style: normal;
  color: var(--cobalt);
  position: relative;
}

.hero-title em::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0.02em;
  height: 0.08em;
  background: var(--amber);
  transform-origin: left;
  animation: underline-in 0.7s cubic-bezier(0.65, 0, 0.35, 1) 0.9s backwards;
}

@keyframes underline-in {
  from {
    transform: scaleX(0);
  }

  to {
    transform: scaleX(1);
  }
}

.hero-sub {
  max-width: 34rem;
  font-size: 1.1875rem;
  color: var(--slate);
  margin-bottom: 1.25rem;
}

.hero-note {
  max-width: 32rem;
  color: var(--ink-soft);
  margin-bottom: 2.25rem;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

/* -- product stack -------------------------------------------------------- */

.hero-visual {
  display: flex;
  justify-content: center;
}

.stack {
  position: relative;
  width: min(26rem, 88vw);
  aspect-ratio: 10 / 9;
}

.stack-glow {
  position: absolute;
  inset: -12%;
  background: radial-gradient(closest-side, var(--cobalt-tint), transparent 72%);
  opacity: var(--glow-opacity);
  pointer-events: none;
}

.window,
.phone,
.chip {
  position: absolute;
  background: var(--paper-raised);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
}

/* browser window */
.win-browser {
  top: 0;
  left: 0;
  width: 76%;
  border-radius: 12px;
  overflow: hidden;
  animation: float 8s ease-in-out infinite;
}

.win-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line);
}

.win-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--line);
}

.win-dot-amber {
  background: var(--amber);
}

.win-url {
  font-family: var(--font-mono);
  font-size: 0.6875rem;
  color: var(--slate);
  background: var(--paper);
  border-radius: 999px;
  padding: 0.15rem 0.7rem;
  margin-left: 0.5rem;
}

.win-body {
  padding: 1.1rem;
  display: grid;
  gap: 0.65rem;
}

/* skeleton lines */
.sk {
  display: block;
  height: 9px;
  border-radius: 5px;
  background: var(--line);
}

.sk-title {
  height: 15px;
  width: 55%;
  background: var(--cobalt);
  opacity: 0.85;
}

/* chart */
.chart {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 74px;
  margin-top: 0.4rem;
}

.bar {
  flex: 1;
  border-radius: 4px 4px 0 0;
  background: var(--cobalt);
  transform-origin: bottom;
  animation: bar-grow 0.8s cubic-bezier(0.34, 1.3, 0.64, 1) backwards;
}

.bar:nth-child(1) { animation-delay: 0.7s; }
.bar:nth-child(2) { animation-delay: 0.8s; }
.bar:nth-child(3) { animation-delay: 0.9s; }
.bar:nth-child(4) { animation-delay: 1s; }
.bar:nth-child(5) { animation-delay: 1.1s; }

.bar-amber {
  background: var(--amber);
}

@keyframes bar-grow {
  from {
    transform: scaleY(0);
  }

  to {
    transform: scaleY(1);
  }
}

/* phone */
.phone {
  top: 16%;
  right: 0;
  width: 33%;
  aspect-ratio: 9 / 17;
  border-radius: 18px;
  padding: 0.8rem 0.7rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  animation: float 7s ease-in-out 0.6s infinite;
}

.phone-notch {
  width: 42%;
  height: 5px;
  border-radius: 999px;
  background: var(--line);
  margin: 0 auto 0.5rem;
}

.phone-tile {
  height: 2.1rem;
  border-radius: 8px;
  background: var(--cobalt-tint);
}

.phone-tile-alt {
  height: 1.6rem;
  opacity: 0.7;
}

.phone-cta {
  margin-top: auto;
  height: 2rem;
  border-radius: 8px;
  background: var(--cobalt);
}

/* deploy chip */
.chip {
  left: 2%;
  bottom: 5%;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  border-radius: 999px;
  padding: 0.55rem 1rem;
  animation: float 6s ease-in-out 1.2s infinite;
}

.chip-text {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--ink-soft);
  white-space: nowrap;
}

.chip-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #2fbf71;
  animation: chip-pulse 2.2s ease-out infinite;
}

@keyframes chip-pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(47, 191, 113, 0.45);
  }

  70% {
    box-shadow: 0 0 0 9px rgba(47, 191, 113, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(47, 191, 113, 0);
  }
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }

  50% {
    transform: translateY(-9px);
  }
}

@media (min-width: 64rem) {
  .hero {
    padding-top: calc(var(--header-h) + 6rem);
    padding-bottom: 7rem;
  }

  .hero-grid {
    grid-template-columns: 7fr 5fr;
    gap: 4rem;
  }
}

/* ==========================================================================
   Sections
   ========================================================================== */

.section {
  padding-block: 5.5rem;
}

.section-head {
  max-width: 38rem;
  margin-bottom: 3.5rem;
}

.section-title {
  font-size: clamp(1.9rem, 4vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
}

.section-sub {
  color: var(--slate);
  font-size: 1.0625rem;
  margin-bottom: 0;
}

.section-alt {
  background: var(--paper-raised);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

@media (min-width: 64rem) {
  .section {
    padding-block: 7.5rem;
  }
}

/* ==========================================================================
   Services
   ========================================================================== */

.service-list {
  border-top: 1px solid var(--line);
}

.service-row {
  display: grid;
  gap: 1rem;
  padding: 2.25rem 0 2.25rem 1.25rem;
  border-bottom: 1px solid var(--line);
  border-left: 3px solid transparent;
  margin-left: -1.25rem;
  padding-left: 1.25rem;
  transition: border-left-color 0.25s ease, background-color 0.25s ease;
}

.service-row:hover {
  border-left-color: var(--cobalt);
  background: linear-gradient(90deg, var(--cobalt-tint), transparent 60%);
}

.service-title {
  font-size: 1.55rem;
  font-weight: 650;
  margin: 0;
}

.service-body p {
  color: var(--slate);
  max-width: 36rem;
}

.tag-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0;
  margin: 0.35rem 0 0;
}

.tag-list li {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--ink-soft);
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.3rem 0.8rem;
}

@media (min-width: 48rem) {
  .service-row {
    grid-template-columns: 2fr 3fr;
    gap: 2.5rem;
    padding-block: 2.75rem;
  }
}

/* ==========================================================================
   Process (band)
   ========================================================================== */

.section-band {
  background: var(--band);
  color: #f2f5fc;
}

.section-band .section-title {
  color: #ffffff;
}

.section-band .section-sub {
  color: #9aa5c4;
}

.section-band .eyebrow {
  color: var(--amber);
}

.process-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2.5rem;
}

.process-step {
  border-top: 1px solid var(--band-line);
  padding-top: 1.5rem;
  display: flex;
  flex-direction: column;
}

.step-num {
  font-family: var(--font-mono);
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--amber);
  letter-spacing: 0.1em;
  display: block;
  margin-bottom: 1rem;
}

.step-title {
  font-size: 1.25rem;
  font-weight: 650;
  color: #ffffff;
  margin-bottom: 0.65rem;
}

.process-step p {
  color: #9aa5c4;
  font-size: 0.9875rem;
  margin: 0;
}

.process-step .step-out {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: #cdd4e8;
  margin-top: 1rem;
}

@media (min-width: 48rem) {
  .process-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem 2.5rem;
  }
}

@media (min-width: 64rem) {
  .process-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ==========================================================================
   Approach
   ========================================================================== */

.approach-grid {
  display: grid;
  gap: 2.5rem;
}

.approach-item {
  border-top: 1px solid var(--line);
  padding-top: 1.5rem;
}

.approach-item h3 {
  font-size: 1.25rem;
  font-weight: 650;
  margin-bottom: 0.65rem;
}

.approach-item h3::before {
  content: "";
  display: block;
  width: 1.6rem;
  height: 3px;
  border-radius: 2px;
  background: var(--cobalt);
  margin-bottom: 1.1rem;
}

.approach-item p {
  color: var(--slate);
  margin: 0;
}

@media (min-width: 48rem) {
  .approach-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 3.5rem 4rem;
  }
}

/* ==========================================================================
   About
   ========================================================================== */

.about-grid {
  display: grid;
  gap: 3.5rem;
  align-items: start;
}

.about-copy p {
  color: var(--ink-soft);
  max-width: 34rem;
}

.about-copy .btn {
  margin-top: 0.75rem;
}

.fact-list {
  margin: 0;
  border-top: 1px solid var(--line);
}

.fact {
  display: grid;
  grid-template-columns: 9.5rem 1fr;
  gap: 1rem;
  padding: 1.15rem 0;
  border-bottom: 1px solid var(--line);
}

.fact dt {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate);
  padding-top: 0.2rem;
}

.fact dd {
  margin: 0;
  font-weight: 500;
}

@media (min-width: 64rem) {
  .about-grid {
    grid-template-columns: 6fr 5fr;
    gap: 5rem;
  }

  .fact-list {
    margin-top: 3.4rem;
  }
}

/* ==========================================================================
   Contact
   ========================================================================== */

.section-contact {
  background: var(--paper);
}

.contact-grid {
  display: grid;
  gap: 3rem;
}

.contact-details {
  font-style: normal;
  margin-top: 2rem;
  border-top: 1px solid var(--line);
}

.contact-details p {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 1rem;
  padding: 1rem 0;
  margin: 0;
  border-bottom: 1px solid var(--line);
}

.detail-label {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--slate);
  padding-top: 0.2rem;
}

.contact-form .field {
  margin-bottom: 1.4rem;
}

.field label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  margin-bottom: 0.5rem;
}

.field input,
.field textarea {
  width: 100%;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.85rem 1rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--cobalt);
  box-shadow: 0 0 0 3px var(--cobalt-tint);
}

.field textarea {
  resize: vertical;
  min-height: 8rem;
}

.field ::placeholder {
  color: var(--placeholder);
}

.field-row {
  display: grid;
  gap: 1.4rem 1.5rem;
}

.form-footer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.form-status {
  margin: 0;
  font-size: 0.9375rem;
  min-height: 1.4em;
}

.form-status.is-error {
  color: var(--error);
}

.success-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper-raised);
  padding: 2.5rem 2rem;
  text-align: center;
}

.success-card .success-icon {
  margin: 0 auto 1.25rem;
  color: var(--cobalt);
}

.success-card h3 {
  font-size: 1.4rem;
}

.success-card p {
  color: var(--slate);
  max-width: 26rem;
  margin-inline: auto;
  margin-bottom: 1.75rem;
}

@media (min-width: 48rem) {
  .field-row {
    grid-template-columns: 1fr 1fr;
  }
}

@media (min-width: 64rem) {
  .contact-grid {
    grid-template-columns: 5fr 6fr;
    gap: 5rem;
  }
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
  background: var(--band);
  color: #9aa5c4;
  padding-top: 4.5rem;
}

.footer-grid {
  display: grid;
  gap: 2.75rem;
  padding-bottom: 3.5rem;
}

.brand-footer .brand-name {
  color: #ffffff;
}

.brand-footer .brand-name-light {
  color: #9aa5c4;
}

.footer-tagline {
  margin-top: 1rem;
  font-size: 0.9375rem;
  max-width: 20rem;
}

.footer-nav,
.footer-contact {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.site-footer h4 {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #6b7699;
  margin-bottom: 0.5rem;
}

.site-footer a {
  color: #cdd4e8;
  font-size: 0.9375rem;
  transition: color 0.2s ease;
}

.site-footer a:hover {
  color: #ffffff;
}

.footer-contact p {
  font-size: 0.9375rem;
  margin: 0;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.75rem;
  border-top: 1px solid var(--band-line);
  padding-block: 1.75rem;
  font-size: 0.875rem;
  color: #6b7699;
}

.footer-bottom p {
  margin: 0;
}

.footer-latin {
  font-family: var(--font-mono);
  font-style: italic;
}

@media (min-width: 48rem) {
  .footer-grid {
    grid-template-columns: 2fr 1.1fr 1fr 1.4fr;
    gap: 2rem;
  }
}

/* ==========================================================================
   Scroll reveal
   ========================================================================== */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
  transition-delay: var(--delay, 0ms);
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Reduced motion
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .win-browser,
  .phone,
  .chip,
  .bar,
  .chip-dot,
  .hero-title em::after {
    animation: none;
  }
}
