/* HardDayz — Hostinger-ready static site */
:root {
  --bg: #f8fafc;
  --surface: #ffffff;
  --text: #0f172a;
  --text-muted: #475569;
  --accent: #0891b2;
  --accent-dark: #0e7490;
  --accent-soft: rgba(8, 145, 178, 0.12);
  --border: #e2e8f0;
  --hero-overlay: rgba(15, 23, 42, 0.78);
  --font: "Plus Jakarta Sans", system-ui, -apple-system, Segoe UI, sans-serif;
  --radius: 12px;
  --shadow: 0 18px 50px rgba(15, 23, 42, 0.08);
  --max: 1120px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
}

body.nav-open {
  overflow: hidden;
}

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

a {
  color: var(--accent-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--accent);
}

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  background: rgba(15, 23, 42, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.site-header.is-scrolled {
  border-color: rgba(255, 255, 255, 0.08);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
}

.logo {
  display: inline-flex;
  align-items: center;
  flex-shrink: 1;
  min-width: 0;
  max-width: min(640px, 92vw);
  max-height: 112px;
  text-decoration: none;
  line-height: 0;
}

.logo:hover {
  opacity: 0.92;
}

.logo-img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  max-height: clamp(88px, 11vw, 104px);
  object-fit: contain;
  object-position: left center;
}

.nav-backdrop {
  display: none;
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.06);
  cursor: pointer;
}

.nav-toggle-bar {
  display: block;
  width: 20px;
  height: 2px;
  background: #fff;
  position: relative;
}

.nav-toggle-bar::before,
.nav-toggle-bar::after {
  content: "";
  position: absolute;
  left: 0;
  width: 20px;
  height: 2px;
  background: #fff;
}

.nav-toggle-bar::before {
  top: -6px;
}

.nav-toggle-bar::after {
  top: 6px;
}

.nav-list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-header .nav-list a {
  color: rgba(255, 255, 255, 0.78);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.95rem;
}

.site-header .nav-list a:hover {
  color: #fff;
}

.site-header .nav-list a.btn-primary {
  color: #fff;
}

.site-header .nav-list a.btn-primary:hover {
  color: #fff;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.7rem 1.25rem;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: 10px;
  border: 2px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.15s;
}

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

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

.btn-primary:hover {
  background: var(--accent-dark);
  border-color: var(--accent-dark);
  color: #fff;
}

.btn-ghost {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.55);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: #fff;
  color: #fff;
}

.btn-outline {
  background: var(--surface);
  color: var(--accent-dark);
  border-color: var(--accent);
}

.btn-outline:hover {
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.hero {
  position: relative;
  min-height: min(92vh, 820px);
  display: flex;
  align-items: center;
  padding: clamp(10rem, 18vh, 12rem) 0 4.5rem;
  color: #fff;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background-color: #0f172a;
  background-image: url("../assets/hero-bg.jpg");
  background-size: cover;
  background-position: center;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: var(--hero-overlay);
}

.hero-inner {
  position: relative;
  z-index: 1;
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

.hero h1 {
  margin: 0 0 1rem;
  font-size: clamp(2rem, 4.5vw, 3.15rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.03em;
  max-width: 18ch;
}

.hero-lead {
  margin: 0 0 2rem;
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: rgba(255, 255, 255, 0.88);
  max-width: 42ch;
}

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

section {
  padding: 4.5rem 0;
}

section:nth-of-type(even) {
  background: var(--surface);
}

.section-head {
  margin-bottom: 2.5rem;
  max-width: 40rem;
}

.section-head h2 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.65rem, 3vw, 2.1rem);
  letter-spacing: -0.02em;
}

.section-head p {
  margin: 0;
  color: var(--text-muted);
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin-top: 2.5rem;
}

.stat {
  padding: 1.25rem 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg);
  text-align: center;
}

.stat strong {
  display: block;
  font-size: 1.15rem;
  color: var(--accent-dark);
  margin-bottom: 0.25rem;
}

.stat span {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.card {
  padding: 1.75rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.card h3 {
  margin: 0 0 0.75rem;
  font-size: 1.2rem;
}

.card p {
  margin: 0;
  color: var(--text-muted);
  font-size: 0.98rem;
}

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

.bullets li {
  position: relative;
  padding-left: 1.35rem;
  color: var(--text-muted);
}

.bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--accent);
}

.bullets li strong {
  color: var(--text);
  font-weight: 600;
}

.portfolio-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.portfolio-grid > .portfolio-item {
  min-width: 0;
}

.portfolio-item {
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px dashed var(--border);
  background: var(--bg);
  min-height: 180px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  text-align: center;
  color: var(--text-muted);
  font-size: 0.95rem;
}

/* Thumbnail: scale screenshot to fit tile (contain); grid min-width:0 prevents overflow clip */
.portfolio-item.portfolio-item--thumb {
  min-height: unset;
  aspect-ratio: 16 / 10;
  background: #0f172a;
  padding: 0;
  border-style: solid;
  display: flex;
  align-items: center;
  justify-content: center;
}

.portfolio-item--thumb img {
  display: block;
  min-width: 0;
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  object-position: center center;
}

.contact-section {
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.05fr;
  gap: 2.5rem;
  align-items: start;
}

.form-note {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 1rem;
}

.form-alert {
  padding: 0.85rem 1rem;
  border-radius: 10px;
  margin-bottom: 1rem;
  font-size: 0.95rem;
}

.form-alert--ok {
  background: #ecfdf5;
  color: #065f46;
  border: 1px solid #a7f3d0;
}

.form-alert--err {
  background: #fef2f2;
  color: #991b1b;
  border: 1px solid #fecaca;
}

.contact-form {
  display: grid;
  gap: 1rem;
}

.field label {
  display: block;
  font-weight: 600;
  font-size: 0.9rem;
  margin-bottom: 0.35rem;
}

.label-hint {
  font-weight: 400;
  color: var(--text-muted);
}

.field input,
.field select,
.field textarea {
  width: 100%;
  padding: 0.65rem 0.85rem;
  font-family: inherit;
  font-size: 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: var(--surface);
}

.field textarea {
  min-height: 140px;
  resize: vertical;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

.site-footer {
  padding: 1.5rem 0;
  border-top: 1px solid var(--border);
  background: var(--surface);
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
}

@media (max-width: 960px) {
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }

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

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

@media (max-width: 768px) {
  .nav-toggle {
    display: inline-flex;
  }

  .nav-backdrop {
    display: block;
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s, visibility 0.2s;
    z-index: 45;
  }

  body.nav-open .nav-backdrop {
    opacity: 1;
    visibility: visible;
  }

  #site-nav {
    position: fixed;
    top: 0;
    right: 0;
    width: min(100% - 3rem, 280px);
    height: 100vh;
    background: var(--surface);
    border-left: 1px solid var(--border);
    padding: 5rem 1.25rem 1.5rem;
    transform: translateX(100%);
    transition: transform 0.25s ease;
    z-index: 48;
    overflow-y: auto;
  }

  #site-nav.is-open {
    transform: translateX(0);
  }

  #site-nav .nav-list {
    flex-direction: column;
    align-items: flex-start;
  }

  #site-nav .nav-list a:not(.btn-primary) {
    color: var(--text-muted);
  }

  #site-nav .nav-list a:not(.btn-primary):hover {
    color: var(--accent-dark);
  }
}
