/* ====================================================
   CSS RESET & NORMALIZE
   ==================================================== */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, menu, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
main, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
  box-sizing: border-box;
}
html {
  box-sizing: border-box;
  scroll-behavior: smooth;
  font-size: 16px;
}
*, *:before, *:after {
  box-sizing: inherit;
}
body {
  line-height: 1.5;
  background: #f5f7fa;
  color: #13345c;
  font-family: 'Roboto', Arial, Helvetica, sans-serif;
  font-size: 1rem;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s;
}
ul, ol {
  list-style: none;
}
button, input, select, textarea {
  font: inherit;
  background: none;
  border: none;
  outline: none;
  color: inherit;
}
button {
  cursor: pointer;
}

/* ====================================================
   VARIABLES & BRAND COLORS (with fallback)
   ==================================================== */
:root {
  --primary: #13345c;
  --secondary: #ff9900;
  --accent: #f5f7fa;
  --body-font: 'Roboto', Arial, Helvetica, sans-serif;
  --display-font: 'Oswald', Arial, Helvetica, sans-serif;
  --radius-xs: 6px;
  --radius-sm: 10px;
  --radius-md: 16px;
  --shadow-md: 0 3px 14px rgba(19,52,92,0.08);
  --shadow-lg: 0 6px 24px rgba(19,52,92,0.14);
  --focus-ring: 0 0 0 2px #ff9900;
  --gradient-modern: linear-gradient(90deg, #13345c 0%, #266bb3 100%);
  --gradient-button: linear-gradient(90deg, #ff9900 0%, #ffbb36 100%);
  --gradient-light: linear-gradient(120deg, #f5f7fa 0%, #e7eef7 100%);
}


/* ====================================================
   LAYOUT CONTAINERS
   ==================================================== */
.container {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  gap: 0;
}
.content-wrapper {
  width: 100%;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.section {
  margin-bottom: 60px;
  padding: 40px 20px;
  background: var(--accent);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* For visual separation of sections */
.section:not(:first-of-type) {
  margin-top: 0;
}

/* FLEXBOX CONTENT PATTERNS */
.card-container, .features-grid, .metrics-grid, .blog-grid, .testimonial-grid, .team-list, .service-list { 
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.card, .feature, .team-member, .metric, .service-item, .testimonial-card, article {
  position: relative;
  margin-bottom: 20px;
}
.content-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
}
.text-image-section {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}
.testimonial-card {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px;
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  min-width: 220px;
  transition: box-shadow 0.2s;
}
.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
}


/* ====================================================
   TYPOGRAPHY
   ==================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--display-font), Arial, Helvetica, sans-serif;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--primary);
  line-height: 1.15;
}
h1 {
  font-size: 2.6rem;
  margin-bottom: 18px;
}
h2 {
  font-size: 2rem;
  margin-bottom: 12px;
}
h3 {
  font-size: 1.34rem;
  margin-bottom: 8px;
}
h4 {
  font-size: 1.1rem;
  margin-bottom: 5px;
}
.subheadline {
  font-size: 1.2rem;
  color: #266bb3;
  font-weight: 400;
  font-family: var(--body-font);
  margin-bottom: 14px;
}
p {
  font-family: var(--body-font), Arial, Helvetica, sans-serif;
  font-size: 1.06rem;
  color: #344a5f;
}
strong {
  font-weight: 700;
}

/* Typography scale for responsive */
@media (max-width: 1024px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.5rem; }
}
@media (max-width: 768px) {
  h1 { font-size: 1.5rem; }
  h2 { font-size: 1.2rem; }
  .section { padding: 26px 8px; }
}


/* ====================================================
   HEADER & NAVIGATION
   ==================================================== */
header {
  width: 100%;
  background: var(--gradient-modern);
  box-shadow: 0 4px 24px rgba(19,52,92, 0.05);
  padding: 0;
  position: relative;
  z-index: 100;
}
header .container {
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  min-height: 80px;
}
.logo img {
  height: 44px;
  width: auto;
  display: block;
}
nav {
  display: flex;
  align-items: center;
  gap: 20px;
}
nav a {
  font-family: var(--body-font);
  font-weight: 500;
  font-size: 1.03rem;
  padding: 8px 12px;
  color: #fff;
  position: relative;
  border-radius: var(--radius-xs);
  transition: background 0.2s, color 0.2s;
}
nav a:hover, nav a:focus {
  background: rgba(255,153,0,0.11);
  color: var(--secondary);
}
.cta.primary {
  background: var(--gradient-button);
  color: #13345c;
  font-family: var(--display-font);
  font-weight: 700;
  font-size: 1.1rem;
  border-radius: var(--radius-sm);
  padding: 13px 28px;
  box-shadow: var(--shadow-md);
  margin-left: 16px;
  letter-spacing: 0.03em;
  border: 2px solid var(--secondary);
  transition: background 0.25s, color 0.2s, box-shadow 0.25s;
  outline: none;
}
.cta.primary:hover, .cta.primary:focus {
  background: var(--primary);
  color: #fff;
  box-shadow: var(--shadow-lg);
}

button.mobile-menu-toggle {
  display: none;
  background: none;
  font-size: 2.2rem;
  color: #fff;
  border: none;
  margin-left: 18px;
  line-height: 1;
  z-index: 1201;
}

/****************** Mobile Menu Styles *******************/
.mobile-menu {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  width: 100vw;
  height: 100vh;
  z-index: 2500;
  background: rgba(19,52,92,0.93);
  flex-direction: column;
  justify-content: flex-start;
  align-items: flex-end;
  transform: translateX(100%);
  transition: transform 0.37s cubic-bezier(0.7,0,0.3,1);
}
.mobile-menu.active {
  display: flex;
  transform: translateX(0);
}
.mobile-menu-close {
  background: none;
  color: #fff;
  font-size: 2.4rem;
  border: none;
  margin: 26px 34px 0 0;
  align-self: flex-end;
  cursor: pointer;
  transition: color 0.18s;
}
.mobile-menu-close:hover, .mobile-menu-close:focus {
  color: var(--secondary);
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  width: 100%;
  padding: 60px 44px 0 36px;
  gap: 22px;
}
.mobile-nav a {
  color: #fff;
  font-size: 1.33rem;
  padding: 12px 0;
  border-radius: var(--radius-xs);
  transition: background 0.2s, color 0.2s;
  width: 100%;
  font-family: var(--display-font);
}
.mobile-nav a:hover, .mobile-nav a:focus {
  background: rgba(255,153,0,0.13);
  color: var(--secondary);
}

/****************** Responsive Header *******************/
@media (max-width: 1024px) {
  header .container {
    gap: 12px;
  }
  nav {
    gap: 12px;
  }
}
@media (max-width: 900px) {
  nav, .cta.primary {
    display: none;
  }
  button.mobile-menu-toggle {
    display: block;
  }
}
@media (max-width: 900px) {
  .logo img {
    height: 36px;
  }
}

/* ====================================================
   SECTIONS, CARDS, FEATURE BOXES
   ==================================================== */
.features-grid, .metrics-grid, .service-list, .team-list, .testimonial-grid, .blog-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  width: 100%;
}
.feature, .service-item, .team-member, .metric, article {
  flex: 1 1 250px;
  min-width: 215px;
  background: #fff;
  border-radius: var(--radius-sm);
  padding: 28px 20px 18px 20px;
  margin-bottom: 20px;
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 13px;
  transition: box-shadow 0.2s, transform 0.14s;
}
.feature:hover, .service-item:hover, .team-member:hover, .metric:hover, article:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-3px) scale(1.018);
}
.feature img, .team-member img, .service-item img {
  width: 46px;
  height: 46px;
  margin-bottom: 8px;
}
.service-price {
  color: var(--secondary);
  font-weight: 700;
  font-size: 1.02rem;
  margin-top: 8px;
}
.metric {
  align-items: flex-start;
  text-align: left;
  font-size: 1.2rem;
  color: var(--primary);
}
.metric strong {
  font-size: 2rem;
  color: var(--secondary);
}

/* CUSTOMER HIGHLIGHT (opinie.html) */
.customer-highlight {
  margin-top: 30px;
  padding: 20px 30px;
  border-radius: var(--radius-md);
  background: var(--gradient-light);
  box-shadow: var(--shadow-md);
  font-family: var(--body-font);
  font-size: 1.1rem;
  color: var(--primary);
}

/* BLOG */
.blog-grid {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
}
.blog-grid article {
  min-width: 220px;
  flex: 1 1 310px;
  background: #fff;
  padding: 32px 22px 20px 22px;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: box-shadow 0.2s, transform 0.14s;
}

/* ====================================================
   TESTIMONIALS
   ==================================================== */
.testimonial-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  min-width: 240px;
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  margin-bottom: 20px;
  color: #13345C;
  transition: box-shadow 0.22s, transform 0.17s;
}
.testimonial-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}
.testimonial-content p {
  font-size: 1.08rem;
  color: #13345C;
  font-family: var(--body-font);
  margin-bottom: 8px;
}
.testimonial-meta {
  font-size: 0.97rem;
  color: #ff9900;
  font-family: var(--display-font);
  font-weight: 600;
  display: flex;
  gap: 7px;
  align-items: center;
}
.testimonial-meta span:last-child {
  color: #ffd700;
  font-size: 1rem;
}

/* ====================================================
   CONTACT INFO
   ==================================================== */
.contact-info {
  display: flex;
  flex-direction: column;
  gap: 13px;
  margin-bottom: 12px;
}
.contact-row {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.04rem;
  color: #13345c;
  background: #fff;
  border-radius: var(--radius-xs);
  padding: 10px 14px;
  box-shadow: var(--shadow-md);
}
.contact-row img {
  width: 26px;
  height: 26px;
}

/* ====================================================
   FOOTER
   ==================================================== */
footer {
  background: var(--primary);
  color: #fff;
  padding: 40px 0 24px 0;
  width: 100%;
}
footer .container {
  flex-direction: column;
  gap: 24px;
  align-items: center;
}
.footer-logo img {
  height: 42px;
}
footer nav {
  display: flex;
  gap: 17px;
  margin-top: 8px;
}
footer nav a {
  font-family: var(--body-font);
  font-size: 1rem;
  padding: 4px 8px;
  color: #fff;
  border-radius: var(--radius-xs);
  transition: background 0.16s, color 0.16s;
}
footer nav a:hover {
  color: var(--secondary);
  background: rgba(255,153,0,0.10);
}
.footer-contact {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 24px;
  margin-top: 17px;
}
.footer-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.97rem;
  color: #fff;
}
.footer-item img {
  width: 18px;
  height: 18px;
}
.footer-copy {
  margin-top: 18px;
  font-size: 0.94rem;
  color: #c8d8ec;
}

/* ====================================================
   BUTTONS, LINKS, FORMS
   ==================================================== */
button, .cta, .cookie-btn {
  cursor: pointer;
  outline: none;
  border: none;
  font-family: var(--display-font), Arial, Helvetica, sans-serif;
  font-weight: 600;
  border-radius: var(--radius-sm);
  transition: background 0.2s, color 0.2s, box-shadow 0.19s, border 0.19s;
  padding: 11px 28px;
}
.cta.primary, .cookie-btn.accept {
  background: var(--gradient-button);
  color: #13345c;
  border: 2px solid var(--secondary);
}
.cta.primary:hover, .cookie-btn.accept:hover, .cta.primary:focus {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
}
.cookie-btn.reject {
  background: #fff;
  color: var(--primary);
  border: 2px solid #c7d1e7;
}
.cookie-btn.reject:hover, .cookie-btn.reject:focus {
  background: #f5f7fa;
  color: #13345c;
  border-color: var(--secondary);
}
.cookie-btn.settings {
  background: #e7eef7;
  color: #13345c;
  border: 2px solid #e7eef7;
}
.cookie-btn.settings:hover, .cookie-btn.settings:focus {
  background: #e3eaf5;
  border-color: var(--secondary);
  color: var(--primary);
}
a.cta {
  display: inline-block;
  margin-top: 12px;
}
a.cta:focus {
  box-shadow: var(--focus-ring);
}

/* ====================================================
   COOKIE BANNER & PREFERENCES MODAL
   ==================================================== */
#cookie-consent {
  position: fixed;
  bottom: 0; left: 0; right: 0;
  z-index: 3000;
  background: #fff;
  box-shadow: 0 -6px 32px rgba(19,52,92,0.17);
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  padding: 20px 28px;
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  gap: 20px;
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.28s cubic-bezier(0.7,0,0.3,1), transform 0.32s cubic-bezier(0.7,0,0.3,1);
}
#cookie-consent.hide {
  opacity: 0;
  pointer-events: none;
  transform: translateY(110%);
}
#cookie-consent .cookie-message {
  font-size: 1.08rem;
  color: #13345c;
  margin-right: 18px;
  flex: 1 1 50%;
}
#cookie-consent .cookie-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* Modal overlay */
#cookie-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(19,52,92,0.58);
  display: none;
  z-index: 3400;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.33s;
  padding: 20px;
}
#cookie-modal-overlay.active {
  display: flex;
}
@keyframes fadeIn {
  from { opacity: 0; } to { opacity: 1; }
}
/* Modal window */
#cookie-modal {
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  max-width: 410px;
  width: 100%;
  padding: 32px 20px 22px 20px;
  color: #13345c;
  display: flex;
  flex-direction: column;
  gap: 17px;
  animation: slideUp 0.38s cubic-bezier(0.7,0,0.3,1);
}
@keyframes slideUp {
  from { transform: translateY(90px); opacity: 0; }
  to   { transform: translateY(0); opacity: 1; }
}
#cookie-modal h2 {
  font-size: 1.4rem;
  margin-bottom: 7px;
}
.cookie-cat {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid #e1e8f1;
}
.cookie-cat:last-child {
  border-bottom: none;
}
.cookie-switch {
  display: flex;
  align-items: center;
  gap: 4px;
}
.cookie-switch input[type="checkbox"] {
  appearance: none;
  width: 37px;
  height: 21px;
  background: #e7eef7;
  border-radius: 22px;
  position: relative;
  outline: none;
  vertical-align: middle;
  transition: background 0.19s;
  cursor: pointer;
}
.cookie-switch input[type="checkbox"]:checked {
  background: var(--gradient-button);
}
.cookie-switch input[type="checkbox"]::after {
  content: '';
  position: absolute;
  left: 3px;
  top: 2.5px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-radius: 50%;
  box-shadow: 0 1px 4px rgba(19,52,92,0.1);
  transition: left 0.2s;
}
.cookie-switch input[type="checkbox"]:checked::after {
  left: 18px;
}
.cookie-switch label {
  font-size: 1.02rem;
  cursor: pointer;
  margin-left: 12px;
}
.cookie-actions-modal {
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: flex-end;
  margin-top: 11px;
}
.cookie-modal-close {
  background: none;
  border: none;
  color: #266bb3;
  font-size: 1.7rem;
  position: absolute;
  top: 11px; right: 15px;
  cursor: pointer;
  transition: color 0.17s;
}
.cookie-modal-close:hover { color: var(--secondary); }


/* ====================================================
   RESPONSIVE & MOBILE STYLES
   ==================================================== */
@media (max-width: 1024px) {
  .container { max-width: 94vw; }
  .features-grid, .metrics-grid, .service-list, .team-list, .testimonial-grid, .blog-grid { gap: 16px; }
}
@media (max-width: 768px) {
  body {
    font-size: 15px;
  }
  .container { padding: 0 8px; }
  .section { margin-bottom: 38px; padding: 18px 4px; gap: 14px; }
  .content-wrapper { gap: 14px; }
  .features-grid, .metrics-grid, .service-list, .team-list, .testimonial-grid, .blog-grid {
    flex-direction: column;
    gap: 13px;
  }
  .feature, .service-item, .team-member, .metric, article {
    padding: 20px 10px 15px 10px;
    min-width: unset;
    font-size: 1rem;
  }
  .testimonial-card {
    flex-direction: column;
    align-items: flex-start;
    min-width: unset;
    padding: 15px 10px;
  }
  .customer-highlight {
    margin-top: 18px;
    padding: 13px 10px;
    font-size: 1rem;
  }
  .blog-grid article {
    padding: 18px 8px 16px 8px;
    min-width: unset;
  }
  .text-image-section {
    flex-direction: column;
    gap: 13px;
  }
  .footer-contact { flex-direction: column; gap: 10px; }
  footer .container { gap: 14px; }
  #cookie-consent { flex-direction: column; align-items: flex-start; padding: 12px 4px; gap: 7px; }
  #cookie-consent .cookie-message { margin-right: 0; }
}
@media (max-width: 500px) {
  .metric strong { font-size: 1.3rem; }
  .footer-logo img { height: 28px; }
}

/* ====================================================
   ANIMATIONS & MICRO-INTERACTIONS
   ==================================================== */
.section, .feature, .service-item, .team-member, .testimonial-card, .card, article {
  transition: box-shadow 0.18s, transform 0.14s, background 0.16s;
}
.cta.primary, .cookie-btn {
  transition: background 0.21s, color 0.2s, border-color 0.21s, box-shadow 0.16s;
}
.card:hover, .feature:hover, .service-item:hover, .team-member:hover, .testimonial-card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px) scale(1.015);
}

/* Focus rings for accessibility */
a:focus, button:focus, .cta.primary:focus, .cookie-btn:focus {
  outline: none;
  box-shadow: var(--focus-ring);
}

/* ====================================================
   UTILITY CLASSES & MISC
   ==================================================== */
.gap-8 { gap: 8px; }
.gap-16 { gap: 16px; }
.mt-16 { margin-top: 16px; }
.mb-16 { margin-bottom: 16px; }
.rounded-md { border-radius: var(--radius-md); }
.shadow-md { box-shadow: var(--shadow-md); }
.flex-row { display: flex; flex-direction: row; }
.flex-col { display: flex; flex-direction: column; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }

/* Hide visually but keep for screen readers */
.visually-hidden {
  border: 0; clip: rect(0 0 0 0); height: 1px;
  margin: -1px; overflow: hidden; padding: 0;
  position: absolute; width: 1px; white-space: nowrap;
}

/* ====================================================
   PRINT
   ==================================================== */
@media print {
  * { color: #000 !important; background: #fff !important; box-shadow: none !important; }
}
