/* ==========================================================
   Anna Wójtowicz — Tłumacz Przysięgły
   Custom CSS — WCAG 2.2 compliant
   Bootstrap 5 + custom design tokens
   ========================================================== */

/* ---------- Design tokens ---------- */
:root {
  --brand-900:   #1a1a2e;
  --brand-800:   #16213e;
  --brand-700:   #0f3460;
  --brand-600:   #1a4a8a;
  --brand-400:   #2d6fc4;
  --brand-100:   #dbeafe;
  --brand-50:    #eff6ff;

  --gold-600:    #92600a;
  --gold-400:    #c48c1a;
  --gold-100:    #fef3c7;
  --gold-50:     #fffbeb;

  --neutral-900: #111827;
  --neutral-700: #374151;
  --neutral-500: #6b7280;
  --neutral-300: #d1d5db;
  --neutral-100: #f3f4f6;
  --neutral-50:  #f9fafb;
  --white:       #ffffff;

  --radius-sm:   4px;
  --radius-md:   8px;
  --radius-lg:   12px;
  --radius-xl:   16px;

  --shadow-sm:   0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.05);
  --shadow-md:   0 4px 12px rgba(0,0,0,.10), 0 2px 4px rgba(0,0,0,.06);
  --shadow-lg:   0 10px 30px rgba(0,0,0,.12), 0 4px 8px rgba(0,0,0,.06);

  --font-serif:  'Georgia', 'Times New Roman', serif;
  --font-sans:   system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --font-mono:   'Courier New', monospace;

  --focus-ring:  0 0 0 3px rgba(45,111,196,.45);
  --transition:  .2s ease;
}

/* ---------- Reset & base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-sans);
  color: var(--neutral-900);
  background: var(--white);
  line-height: 1.65;
  margin: 0;
}

/* WCAG: skip link */
.skip-link {
  position: absolute;
  top: -100%;
  left: 1rem;
  background: var(--brand-700);
  color: var(--white);
  padding: .5rem 1rem;
  border-radius: 0 0 var(--radius-md) var(--radius-md);
  font-weight: 600;
  text-decoration: none;
  z-index: 9999;
  transition: top var(--transition);
}
.skip-link:focus { top: 0; }

/* WCAG focus visible */
:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
  border-radius: var(--radius-sm);
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 3px solid var(--brand-400);
  outline-offset: 2px;
  box-shadow: none;
}

/* ---------- Typography ---------- */
h1,h2,h3,h4,h5,h6 {
  font-family: var(--font-serif);
  color: var(--brand-900);
  line-height: 1.25;
  margin-bottom: .5em;
}
h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: clamp(1.1rem, 2.5vw, 1.5rem); }

p { margin-bottom: 1rem; }

a {
  color: var(--brand-600);
  text-underline-offset: 3px;
}
a:hover { color: var(--brand-700); }

/* ---------- Navbar ---------- */
.site-navbar {
  background: var(--brand-900);
  padding: .75rem 0;
  position: sticky;
  top: 0;
  z-index: 1030;
  box-shadow: var(--shadow-md);
}

.site-navbar .brand-name {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  color: var(--white);
  text-decoration: none;
  line-height: 1.25;
}
.site-navbar .brand-name span {
  display: block;
  font-family: var(--font-sans);
  font-size: .7rem;
  font-weight: 400;
  color: rgba(255,255,255,.65);
  text-transform: uppercase;
  letter-spacing: .06em;
}
.site-navbar .brand-name:hover { color: var(--brand-100); }

.site-navbar .nav-link {
  color: rgba(255,255,255,.8) !important;
  font-size: .9rem;
  padding: .4rem .75rem !important;
  border-radius: var(--radius-md);
  transition: background var(--transition), color var(--transition);
}
.site-navbar .nav-link:hover,
.site-navbar .nav-link:focus-visible {
  color: var(--white) !important;
  background: rgba(255,255,255,.1);
}

.navbar-toggler {
  border-color: rgba(255,255,255,.3) !important;
}
.navbar-toggler-icon {
  filter: invert(1);
}

/* ---------- Hero ---------- */
.hero-section {
  background: linear-gradient(135deg, var(--brand-900) 0%, var(--brand-700) 60%, var(--brand-600) 100%);
  color: var(--white);
  padding: 5rem 0 4rem;
  position: relative;
  overflow: hidden;
}
.hero-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E") repeat;
  pointer-events: none;
}

.hero-section .badge-pill {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  background: rgba(255,255,255,.12);
  border: 1px solid rgba(255,255,255,.2);
  color: var(--white);
  padding: .35rem .9rem;
  border-radius: 100px;
  font-size: .8rem;
  font-weight: 500;
  margin-bottom: 1.25rem;
}
.hero-section .badge-pill.weekend {
  background: rgba(234,179,8,.15);
  border-color: rgba(234,179,8,.3);
  color: #fde68a;
}

.hero-title {
  font-family: var(--font-serif);
  font-size: clamp(2rem, 5vw, 3.2rem);
  color: var(--white);
  line-height: 1.2;
  margin-bottom: 1rem;
}

.hero-subtitle {
  font-size: 1.1rem;
  color: rgba(255,255,255,.8);
  max-width: 520px;
  margin-bottom: 2rem;
  line-height: 1.65;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: .75rem;
  align-items: center;
}

/* ---------- Language pills ---------- */
.lang-pills {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-bottom: 2.5rem;
}
.lang-pill {
  background: rgba(255,255,255,.1);
  border: 1px solid rgba(255,255,255,.2);
  color: rgba(255,255,255,.9);
  padding: .3rem .85rem;
  border-radius: 100px;
  font-size: .82rem;
  font-weight: 500;
}

/* ---------- Buttons ---------- */
.btn-brand {
  background: var(--brand-400);
  border: 2px solid var(--brand-400);
  color: var(--white);
  font-weight: 600;
  padding: .65rem 1.5rem;
  border-radius: var(--radius-md);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  transition: background var(--transition), border-color var(--transition), transform var(--transition);
}
.btn-brand:hover {
  background: var(--brand-600);
  border-color: var(--brand-600);
  color: var(--white);
  transform: translateY(-1px);
}
.btn-brand:active { transform: translateY(0); }

.btn-outline-white {
  background: transparent;
  border: 2px solid rgba(255,255,255,.5);
  color: var(--white);
  font-weight: 600;
  padding: .65rem 1.5rem;
  border-radius: var(--radius-md);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: .45rem;
  transition: background var(--transition), border-color var(--transition);
}
.btn-outline-white:hover {
  background: rgba(255,255,255,.1);
  border-color: rgba(255,255,255,.8);
  color: var(--white);
}

/* ---------- Section generic ---------- */
.section { padding: 4rem 0; }
.section-alt { background: var(--neutral-50); }
.section-dark {
  background: var(--brand-900);
  color: var(--white);
}
.section-dark h2,
.section-dark h3 { color: var(--white); }

.section-label {
  display: inline-block;
  font-size: .75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--brand-400);
  margin-bottom: .5rem;
}
.section-dark .section-label { color: var(--brand-100); }

/* ---------- Service cards ---------- */
.service-card {
  background: var(--white);
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  height: 100%;
  transition: box-shadow var(--transition), border-color var(--transition), transform var(--transition);
  position: relative;
}
.service-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--brand-400);
  transform: translateY(-2px);
}
.service-card .icon-wrap {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 1rem;
  color: var(--brand-600);
}
.service-card h3 {
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 700;
  color: var(--neutral-900);
  margin-bottom: .4rem;
}
.service-card p {
  font-size: .9rem;
  color: var(--neutral-700);
  margin: 0;
}

/* ---------- Hours block ---------- */
.hours-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: .5rem;
}
.hours-day {
  text-align: center;
  padding: .75rem .5rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--neutral-300);
  background: var(--white);
  font-size: .8rem;
}
.hours-day.today {
  border-color: var(--brand-400);
  background: var(--brand-50);
}
.hours-day.email-only {
  background: var(--gold-50);
  border-color: #fcd34d;
}
.hours-day .day-name {
  font-weight: 700;
  font-size: .7rem;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--neutral-500);
  display: block;
  margin-bottom: .25rem;
}
.hours-day.today .day-name { color: var(--brand-600); }
.hours-day.email-only .day-name { color: var(--gold-600); }
.hours-day .day-hours {
  color: var(--neutral-900);
  font-size: .78rem;
  line-height: 1.3;
}
.hours-day.email-only .day-hours { color: var(--gold-600); font-size: .72rem; }

@media (max-width: 576px) {
  .hours-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ---------- Stats row ---------- */
.stat-item {
  text-align: center;
  padding: 1.5rem 1rem;
}
.stat-num {
  font-family: var(--font-serif);
  font-size: 2.25rem;
  font-weight: 700;
  color: var(--brand-400);
  line-height: 1;
  margin-bottom: .25rem;
}
.stat-label {
  font-size: .85rem;
  color: rgba(255,255,255,.7);
}

/* ---------- Contact card ---------- */
.contact-card {
  background: var(--white);
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-lg);
  padding: 1.5rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: inherit;
  transition: box-shadow var(--transition), border-color var(--transition);
}
.contact-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--brand-400);
  color: inherit;
}
.contact-card .icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-md);
  background: var(--brand-50);
  color: var(--brand-600);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
}
.contact-card .label {
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .07em;
  color: var(--neutral-500);
}
.contact-card .value {
  font-size: 1rem;
  font-weight: 700;
  color: var(--neutral-900);
}

/* ---------- Form section ---------- */
.form-section {
  background: var(--white);
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-sm);
}
.form-section .form-label {
  font-weight: 600;
  font-size: .85rem;
  color: var(--neutral-700);
  margin-bottom: .35rem;
}
.form-section .form-control,
.form-section .form-select {
  border: 1.5px solid var(--neutral-300);
  border-radius: var(--radius-md);
  padding: .6rem .9rem;
  font-size: .95rem;
  transition: border-color var(--transition), box-shadow var(--transition);
  background: var(--neutral-50);
}
.form-section .form-control:focus,
.form-section .form-select:focus {
  border-color: var(--brand-400);
  box-shadow: 0 0 0 3px rgba(45,111,196,.15);
  background: var(--white);
  outline: none;
}
.form-section .form-control.is-invalid,
.form-section .form-select.is-invalid {
  border-color: #dc2626;
}

/* Drop zone */
.drop-zone {
  border: 2px dashed var(--neutral-300);
  border-radius: var(--radius-lg);
  padding: 2.5rem 1.5rem;
  text-align: center;
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
  background: var(--neutral-50);
  position: relative;
}
.drop-zone:hover,
.drop-zone.drag-over {
  border-color: var(--brand-400);
  background: var(--brand-50);
}
.drop-zone:focus-within {
  outline: 3px solid var(--brand-400);
  outline-offset: 2px;
}
.drop-zone .drop-icon {
  width: 52px; height: 52px;
  margin: 0 auto .75rem;
  border-radius: var(--radius-md);
  border: 1px solid var(--neutral-300);
  background: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  color: var(--brand-400);
}
.drop-zone p { margin: 0; font-size: .9rem; color: var(--neutral-500); }
.drop-zone strong { color: var(--neutral-900); }
.drop-zone small { font-size: .78rem; color: var(--neutral-500); }

/* File list */
.file-list { display: flex; flex-direction: column; gap: .4rem; }
.file-item {
  display: flex;
  align-items: center;
  gap: .75rem;
  background: var(--neutral-50);
  border: 1px solid var(--neutral-300);
  border-radius: var(--radius-md);
  padding: .5rem .85rem;
  font-size: .88rem;
}
.file-item .file-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-item .file-size { font-size: .75rem; color: var(--neutral-500); }
.file-remove {
  background: none;
  border: none;
  color: var(--neutral-500);
  cursor: pointer;
  padding: 2px;
  line-height: 1;
  border-radius: var(--radius-sm);
  transition: color var(--transition);
  font-size: 1.1rem;
}
.file-remove:hover { color: #dc2626; }

/* Progress */
.upload-progress {
  width: 100%;
  height: 4px;
  background: var(--neutral-200);
  border-radius: 2px;
  overflow: hidden;
  display: none;
}
.upload-progress .bar {
  height: 100%;
  background: var(--brand-400);
  border-radius: 2px;
  width: 0%;
  transition: width .3s ease;
}

/* Estimate row */
.estimate-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--neutral-100);
  border-radius: var(--radius-md);
  padding: .75rem 1rem;
  font-size: .9rem;
}
.estimate-row span { color: var(--neutral-500); }
.estimate-row strong { font-weight: 700; color: var(--neutral-900); }

/* Weekend note */
.weekend-alert {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  background: var(--gold-50);
  border: 1px solid #fcd34d;
  border-radius: var(--radius-md);
  padding: .85rem 1rem;
  font-size: .88rem;
  color: var(--gold-600);
}
.weekend-alert i { font-size: 1rem; flex-shrink: 0; margin-top: 1px; }

/* Success state */
.success-panel {
  display: none;
  text-align: center;
  padding: 3rem 2rem;
}
.success-panel.visible { display: block; }
.success-icon {
  width: 64px; height: 64px;
  border-radius: 50%;
  background: #dcfce7;
  border: 2px solid #86efac;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  font-size: 1.75rem;
  color: #16a34a;
}

/* ---------- Trust badges ---------- */
.trust-badge {
  display: flex;
  align-items: center;
  gap: .6rem;
  font-size: .85rem;
  color: rgba(255,255,255,.8);
}
.trust-badge i { color: #fbbf24; font-size: 1rem; }

/* ---------- PKD info ---------- */
.pkd-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.pkd-list li {
  padding: .5rem 0;
  border-bottom: 1px solid var(--neutral-200);
  font-size: .9rem;
  display: flex;
  gap: .75rem;
  align-items: baseline;
}
.pkd-list li:last-child { border: none; }
.pkd-code {
  font-family: var(--font-mono);
  font-size: .8rem;
  font-weight: 700;
  color: var(--brand-600);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  padding: .1rem .45rem;
  border-radius: var(--radius-sm);
  white-space: nowrap;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--neutral-900);
  color: rgba(255,255,255,.7);
  padding: 3rem 0 1.5rem;
  font-size: .88rem;
}
.site-footer h4 {
  font-family: var(--font-sans);
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: rgba(255,255,255,.45);
  margin-bottom: .75rem;
}
.site-footer a {
  color: rgba(255,255,255,.65);
  text-decoration: none;
}
.site-footer a:hover { color: var(--white); }
.site-footer .footer-bottom {
  border-top: 1px solid rgba(255,255,255,.08);
  margin-top: 2rem;
  padding-top: 1.25rem;
  font-size: .8rem;
  color: rgba(255,255,255,.4);
}

/* ---------- Map embed ---------- */
.map-embed {
  border-radius: var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--neutral-300);
  height: 280px;
}
.map-embed iframe {
  width: 100%;
  height: 100%;
  border: none;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
  .hero-section { padding: 3rem 0 2.5rem; }
  .form-section { padding: 1.5rem; }
  .hero-cta { flex-direction: column; align-items: flex-start; }
}
