/* ============================================================
   Sepanta Softwares — styles.css
   Clean & corporate design system. Vanilla CSS, no build step.
   ============================================================ */

/* ---- Design tokens ---- */
:root {
  --color-navy: #0F2A5C;
  --color-primary: #1D4ED8;
  --color-primary-hover: #1E40AF;
  --color-accent: #38BDF8;

  --color-text: #0F172A;
  --color-muted: #475569;
  --color-border: #E2E8F0;
  --color-surface: #F8FAFC;
  --color-surface-2: #EEF2F8;
  --color-white: #FFFFFF;

  --color-footer-bg: #0B1F44;
  --color-footer-text: #C7D2E4;
  --color-footer-heading: #FFFFFF;

  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji", sans-serif;
  --fs-300: 0.875rem;
  --fs-400: 1rem;
  --fs-500: 1.125rem;
  --fs-600: 1.375rem;
  --fs-700: 1.75rem;
  --fs-800: 2.25rem;
  --fs-900: clamp(2.25rem, 5vw, 3.25rem);
  --lh-tight: 1.15;
  --lh-body: 1.65;

  --container: 1120px;
  --gutter: 1.25rem;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06), 0 1px 3px rgba(15, 23, 42, 0.08);
  --shadow-md: 0 10px 30px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 45px rgba(15, 23, 42, 0.12);

  --transition: 180ms ease;
}

/* ---- Reset / base ---- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-size: var(--fs-400);
  line-height: var(--lh-body);
  color: var(--color-text);
  background: var(--color-white);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { max-width: 100%; display: block; }
a { color: var(--color-primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { color: var(--color-navy); line-height: var(--lh-tight); margin: 0 0 0.5em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: var(--fs-900); }
h2 { font-size: var(--fs-800); }
h3 { font-size: var(--fs-600); }
p { margin: 0 0 1rem; }
ul { margin: 0 0 1rem; padding-left: 1.25rem; }
:focus-visible { outline: 3px solid var(--color-accent); outline-offset: 2px; border-radius: 4px; }

/* ---- Skip link ---- */
.skip-link { position: absolute; left: -9999px; top: 0; z-index: 100; background: var(--color-navy); color: #fff; padding: 0.75rem 1rem; border-radius: 0 0 8px 0; }
.skip-link:focus { left: 0; }

/* ---- Container ---- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }

/* ---- Buttons ---- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 0.5rem; font: inherit; font-weight: 600; line-height: 1; padding: 0.8rem 1.35rem; border-radius: 999px; border: 2px solid transparent; cursor: pointer; transition: background var(--transition), color var(--transition), border-color var(--transition), transform var(--transition); text-decoration: none; }
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn-primary { background: var(--color-primary); color: #fff; }
.btn-primary:hover { background: var(--color-primary-hover); color: #fff; }
.btn-outline { background: transparent; color: var(--color-primary); border-color: var(--color-border); }
.btn-outline:hover { border-color: var(--color-primary); color: var(--color-primary); }
.btn-lg { padding: 1rem 1.75rem; font-size: var(--fs-500); }
.btn-ghost-light { background: rgba(255,255,255,0.12); color: #fff; border-color: rgba(255,255,255,0.35); }
.btn-ghost-light:hover { background: rgba(255,255,255,0.2); color: #fff; }

/* ---- Header ---- */
.site-header { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,0.92); backdrop-filter: saturate(180%) blur(8px); border-bottom: 1px solid var(--color-border); transition: box-shadow var(--transition); }
.site-header.is-scrolled { box-shadow: var(--shadow-sm); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 0.6rem; font-weight: 700; color: var(--color-navy); }
.brand:hover { text-decoration: none; }
.brand-mark { width: 30px; height: 30px; flex: none; }
.brand-name { font-size: 1.15rem; letter-spacing: -0.02em; }
.brand-name span { color: var(--color-primary); }
.nav { display: flex; align-items: center; gap: 1.5rem; }
.nav-list { display: flex; align-items: center; gap: 1.4rem; list-style: none; margin: 0; padding: 0; }
.nav-link { color: var(--color-text); font-weight: 500; }
.nav-link:hover, .nav-link[aria-current="page"] { color: var(--color-primary); text-decoration: none; }
.nav-link[aria-current="page"] { font-weight: 600; }
.nav-toggle { display: none; width: 44px; height: 44px; border: 1px solid var(--color-border); border-radius: 10px; background: #fff; cursor: pointer; align-items: center; justify-content: center; }
.nav-toggle-bar, .nav-toggle-bar::before, .nav-toggle-bar::after { content: ""; display: block; width: 20px; height: 2px; background: var(--color-navy); transition: transform var(--transition), opacity var(--transition); }
.nav-toggle-bar { position: relative; }
.nav-toggle-bar::before { position: absolute; top: -6px; left: 0; }
.nav-toggle-bar::after { position: absolute; top: 6px; left: 0; }

@media (max-width: 839px) {
  .nav-toggle { display: inline-flex; }
  .nav { position: fixed; inset: 68px 0 auto 0; background: #fff; flex-direction: column; align-items: stretch; gap: 0; padding: 0.5rem var(--gutter) 1.25rem; border-bottom: 1px solid var(--color-border); box-shadow: var(--shadow-md); transform: translateY(-140%); transition: transform 220ms ease; visibility: hidden; }
  .nav.is-open { transform: translateY(0); visibility: visible; }
  .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
  .nav-link { display: block; padding: 0.85rem 0.25rem; border-bottom: 1px solid var(--color-border); }
  .nav .btn { margin-top: 0.85rem; }

  /* No-JS fallback: no hamburger; nav becomes a static stacked block under the brand */
  html:not(.js) .nav-toggle { display: none; }
  html:not(.js) .header-inner { flex-wrap: wrap; height: auto; padding-block: 0.75rem; row-gap: 0.25rem; }
  html:not(.js) .nav { position: static; inset: auto; transform: none; visibility: visible; box-shadow: none; border-bottom: 0; width: 100%; padding: 0; }
}

/* ---- Sections ---- */
.section { padding: clamp(3rem, 7vw, 5.5rem) 0; }
.section-alt { background: var(--color-surface); }
.section-head { max-width: 720px; margin-bottom: 2.5rem; }
.section-head.center { margin-inline: auto; text-align: center; }
.eyebrow { text-transform: uppercase; letter-spacing: 0.12em; font-size: var(--fs-300); font-weight: 700; color: var(--color-primary); margin: 0 0 0.6rem; }
.lead { font-size: var(--fs-500); color: var(--color-muted); }
.muted { color: var(--color-muted); }
.text-center { text-align: center; }

/* ---- Grid ---- */
.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 980px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; } }

/* ---- Cards ---- */
.card { background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius); padding: 1.6rem; box-shadow: var(--shadow-sm); transition: box-shadow var(--transition), transform var(--transition); }
.card:hover { box-shadow: var(--shadow-md); transform: translateY(-2px); }
.card h3 { margin-top: 0.35rem; }
.card ul { margin-bottom: 0; }
.card ul li { margin-bottom: 0.3rem; }
.card-icon { width: 46px; height: 46px; display: inline-flex; align-items: center; justify-content: center; border-radius: 12px; background: var(--color-surface-2); color: var(--color-primary); margin-bottom: 0.4rem; }
.card-icon svg { width: 24px; height: 24px; }

/* ---- Hero ---- */
.hero { position: relative; padding: clamp(3.5rem, 8vw, 6.5rem) 0; background: radial-gradient(1200px 500px at 80% -10%, rgba(56,189,248,0.14), transparent 60%), linear-gradient(180deg, #fff 0%, var(--color-surface) 100%); }
.hero-inner { max-width: 760px; }
.hero h1 { margin-bottom: 1rem; }
.hero-sub { font-size: var(--fs-500); color: var(--color-muted); margin-bottom: 1.75rem; max-width: 620px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.85rem; }

/* ---- Values ---- */
.value h3 { font-size: var(--fs-500); margin-bottom: 0.35rem; }
.value .card-icon { margin-bottom: 0.6rem; }

/* ---- Featured project ---- */
.featured { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 2rem; align-items: center; background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius); padding: 2rem; box-shadow: var(--shadow-sm); }
.featured-visual { background: linear-gradient(135deg, var(--color-navy), var(--color-primary)); border-radius: var(--radius); min-height: 220px; display: flex; align-items: center; justify-content: center; color: #fff; padding: 1.5rem; text-align: center; }
@media (max-width: 780px) { .featured { grid-template-columns: 1fr; } }

/* ---- Badges / tags ---- */
.badge { display: inline-flex; align-items: center; gap: 0.4rem; font-size: var(--fs-300); font-weight: 600; color: var(--color-primary); background: var(--color-surface-2); padding: 0.3rem 0.7rem; border-radius: 999px; }
.tag-list { display: flex; flex-wrap: wrap; gap: 0.5rem; list-style: none; padding: 0; margin: 0; }
.tag { font-size: var(--fs-300); font-weight: 600; color: var(--color-navy); background: var(--color-surface-2); border: 1px solid var(--color-border); padding: 0.4rem 0.8rem; border-radius: 999px; }

/* ---- CTA band ---- */
.cta-band { background: linear-gradient(135deg, var(--color-navy), var(--color-primary)); color: #fff; border-radius: var(--radius); padding: clamp(2rem, 5vw, 3rem); text-align: center; }
.cta-band h2 { color: #fff; }
.cta-band p { color: rgba(255,255,255,0.85); max-width: 560px; margin-inline: auto; }
.cta-actions { display: flex; gap: 0.85rem; justify-content: center; flex-wrap: wrap; margin-top: 1.25rem; }

/* ---- Service detail ---- */
.service-detail { display: grid; grid-template-columns: 64px 1fr; gap: 1.25rem; padding: 1.75rem 0; border-top: 1px solid var(--color-border); }
.service-detail:first-of-type { border-top: 0; }
.service-detail .card-icon { width: 56px; height: 56px; }
.service-detail .card-icon svg { width: 28px; height: 28px; }
@media (max-width: 560px) { .service-detail { grid-template-columns: 1fr; } }

/* ---- Project cards ---- */
.project-card .badge { margin-bottom: 0.6rem; }
.project-card.placeholder { border-style: dashed; background: var(--color-surface); }
.project-card .todo { font-size: var(--fs-300); color: var(--color-muted); margin-bottom: 0; }

/* ---- Contact ---- */
.contact-card { text-align: center; background: #fff; border: 1px solid var(--color-border); border-radius: var(--radius); padding: clamp(2rem, 5vw, 3.5rem); box-shadow: var(--shadow-sm); max-width: 680px; margin-inline: auto; }
.email-link { display: inline-block; font-size: var(--fs-700); font-weight: 700; color: var(--color-primary); margin: 0.5rem 0 1rem; word-break: break-word; }

/* ---- Disclaimer ---- */
.disclaimer { font-size: var(--fs-300); color: var(--color-muted); border-left: 3px solid var(--color-border); padding-left: 0.9rem; }

/* ---- Footer ---- */
.site-footer { background: var(--color-footer-bg); color: var(--color-footer-text); padding: 3rem 0 1.5rem; margin-top: 2rem; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr; gap: 2rem; padding-bottom: 2rem; border-bottom: 1px solid rgba(255,255,255,0.12); }
.site-footer h4 { color: var(--color-footer-heading); font-size: var(--fs-400); text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 0.9rem; }
.site-footer a { color: var(--color-footer-text); }
.site-footer a:hover { color: #fff; }
.footer-brand .brand-name, .footer-brand .brand { color: #fff; }
.footer-brand .brand-name span { color: var(--color-accent); }
.footer-brand p { margin-top: 0.9rem; max-width: 34ch; }
.footer-links { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.55rem; }
.footer-bottom { display: flex; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding-top: 1.25rem; font-size: var(--fs-300); }
@media (max-width: 720px) { .footer-grid { grid-template-columns: 1fr; gap: 1.5rem; } }

/* ---- Reveal on scroll (gated behind html.js so no-JS shows everything) ---- */
.reveal { opacity: 1; transform: none; }
html.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 500ms ease, transform 500ms ease; }
html.js .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.js .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover, .card:hover { transform: none; }
}
