/* ===========================================
   PhaSta Domum — responsive.css
   Breakpointi:
   - Desktop large : > 1200px
   - Desktop       : 1024px – 1200px
   - Tablet        : 768px – 1023px
   - Mobile large  : 480px – 767px
   - Mobile small  : < 480px
=========================================== */

/* ── Base fluid helpers ── */
img, picture, video, iframe {
  display: block;
  max-width: 100%;
}

* { box-sizing: border-box; }

body { overflow-x: hidden; }

/* ── Container — fluid sa max-width ── */
.container {
  width: min(1180px, calc(100% - 40px));
  margin-inline: auto;
}

/* Section-card container override */
.section-card > .container {
  width: 100% !important;
  max-width: 100% !important;
  margin-inline: 0 !important;
  padding-left: clamp(20px, 4vw, 56px) !important;
  padding-right: clamp(20px, 4vw, 56px) !important;
}

/* ── Typography — fluid scaling ── */
h1 { font-size: clamp(1.8rem, 4vw, 3.2rem); line-height: 1.1; }
h2 { font-size: clamp(1.5rem, 3vw, 2.6rem); line-height: 1.15; }
h3 { font-size: clamp(1.15rem, 2.2vw, 1.8rem); line-height: 1.2; }
p, li { font-size: clamp(0.9rem, 1.5vw, 1rem); }

/* ── Section padding — fluid ── */
.section, .hero, .stats-strip {
  padding-top: clamp(36px, 6vw, 80px);
  padding-bottom: clamp(36px, 6vw, 80px);
}

/* ===========================================
   DESKTOP LARGE  > 1200px
=========================================== */
@media (min-width: 1200px) {
  .hero-mobile-grid {
    grid-template-columns: 1fr 1.1fr;
    gap: 48px;
  }

  .dog-profile-inner {
    grid-template-columns: 400px 1fr;
    gap: 56px;
  }

  .dog-profile-card.reverse .dog-profile-inner {
    grid-template-columns: 1fr 400px;
  }

  .breed-grid-stacked {
    grid-template-columns: 1fr 1fr;
    gap: 32px;
  }

  .footer-grid {
    grid-template-columns: 1.4fr 1fr 1fr;
  }
}

/* ===========================================
   DESKTOP  1024px – 1199px
=========================================== */
@media (max-width: 1199px) {
  .container {
    width: calc(100% - 32px);
  }

  .hero-mobile-grid {
    grid-template-columns: 1fr 1fr;
    gap: 28px;
  }

  .dog-profile-inner,
  .dog-profile-card.reverse .dog-profile-inner {
    grid-template-columns: 340px 1fr;
    gap: 36px;
  }

  .dog-profile-card.reverse .dog-profile-inner {
    grid-template-columns: 1fr 340px;
  }

  .breed-grid-stacked {
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }

  .footer-grid {
    grid-template-columns: 1.2fr 1fr 1fr;
    gap: 28px;
  }

  .value-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
  }

  .stats-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  .contact-grid {
    grid-template-columns: 1fr minmax(300px, 440px);
    gap: 32px;
  }

  .litters-wrap {
    grid-template-columns: 1fr minmax(280px, 380px);
    gap: 32px;
  }

  .section-card {
    width: calc(100% - 32px) !important;
  }
}

/* ===========================================
   TABLET  768px – 1023px
=========================================== */
@media (max-width: 1023px) {
  .container {
    width: calc(100% - 28px);
  }

  /* Navigation */
  .nav-toggle {
    display: inline-flex !important;
    flex-direction: column;
    flex-shrink: 0;
  }

  .site-nav {
    display: none !important;
    position: absolute !important;
    top: calc(100% + 8px) !important;
    left: 0 !important;
    right: 0 !important;
    width: 100% !important;
    flex-direction: column !important;
    align-items: stretch !important;
    padding: 14px !important;
    border-radius: 16px !important;
    background: var(--bg-dark) !important;
    box-shadow: 0 12px 32px rgba(0,0,0,0.25) !important;
    z-index: 2500 !important;
    gap: 6px !important;
  }

  .site-nav.is-open {
    display: flex !important;
  }

  .site-nav a {
    text-align: center !important;
    padding: 11px 14px !important;
    border-radius: 12px !important;
    display: block !important;
    width: 100% !important;
  }

  body.menu-open { overflow: hidden !important; }

  /* Lang switcher on tablet */
  .lang-switcher {
    position: absolute !important;
    top: 50% !important;
    right: 72px !important;
    transform: translateY(-50%) !important;
  }

  /* Hero */
  .hero-mobile-grid {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }

  .hero-mobile-image-wrap {
    order: 1 !important;
    min-height: 360px !important;
  }

  .hero-mobile-image {
    height: 360px !important;
    min-height: 360px !important;
    object-fit: cover !important;
  }

  .hero-mobile-text {
    order: 2 !important;
  }

  .hero-mobile-text h1 {
    font-size: clamp(1.7rem, 4vw, 2.4rem) !important;
  }

  .hero-actions {
    flex-direction: row !important;
    flex-wrap: wrap !important;
  }

  /* Stats */
  .stats-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 12px !important;
  }

  /* About */
  .split-grid {
    grid-template-columns: 1fr !important;
  }

  .sticky-block {
    position: static !important;
  }

  .value-grid {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  /* Dog profile cards */
  .dog-profile-inner,
  .dog-profile-card.reverse .dog-profile-inner {
    grid-template-columns: 1fr !important;
    gap: 20px !important;
  }

  .dog-profile-card.reverse .dog-profile-image-wrap {
    order: 1 !important;
  }

  .dog-profile-card.reverse .dog-profile-body {
    order: 2 !important;
  }

  .dog-profile-image-wrap img {
    max-height: 340px !important;
  }

  .dog-profile-card {
    padding: 36px 24px !important;
  }

  /* Breeds */
  .breed-grid-stacked {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  .breed-card-stacked .breed-image img {
    height: 300px !important;
    max-height: 300px !important;
  }

  /* Litters */
  .litters-wrap {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  /* Contact */
  .contact-grid {
    grid-template-columns: 1fr !important;
    gap: 28px !important;
  }

  .contact-cards-layout {
    grid-template-columns: 1fr 1fr !important;
  }

  .field-grid {
    grid-template-columns: 1fr 1fr !important;
  }

  /* Gallery */
  .per-dog-grid {
    grid-template-columns: repeat(3, 1fr) !important;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 28px !important;
  }

  .footer-brand {
    grid-column: 1 / -1 !important;
  }

  /* Section cards */
  .section-card {
    width: calc(100% - 24px) !important;
    border-radius: 22px !important;
  }
}

/* ===========================================
   MOBILE LARGE  480px – 767px
=========================================== */
@media (max-width: 767px) {
  .container {
    width: calc(100% - 20px);
  }

  /* Hero */
  .hero-mobile-image-wrap {
    min-height: 280px !important;
    border-radius: 18px !important;
    padding: 0 !important;
    background: transparent !important;
  }

  .hero-mobile-image {
    width: 100% !important;
    height: 300px !important;
    min-height: 300px !important;
    max-height: 300px !important;
    object-fit: cover !important;
    border-radius: 18px !important;
  }

  .hero-mobile-image-wrap::after {
    display: block !important;
    border-radius: 18px !important;
  }

  .hero-mobile-overlay-text {
    font-size: 0.95rem !important;
    left: 16px !important;
    right: 16px !important;
    bottom: 16px !important;
  }

  .hero-mobile-text h1 {
    font-size: 1.7rem !important;
  }

  .hero-actions {
    flex-direction: column !important;
    align-items: stretch !important;
  }

  .hero-actions .btn {
    width: 100% !important;
    text-align: center !important;
  }

  /* Stats */
  .stats-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 10px !important;
  }

  .stats-grid article strong {
    font-size: 1.6rem !important;
  }

  /* Value cards */
  .value-grid {
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  /* Dog profile */
  .dog-profile-card {
    padding: 28px 16px !important;
  }

  .dog-profile-name {
    font-size: 1.35rem !important;
  }

  .dog-fact-row {
    grid-template-columns: 90px 1fr !important;
    padding: 9px 14px !important;
  }

  .dog-fact-row span {
    font-size: 0.74rem !important;
  }

  /* Breeds */
  .breed-card-stacked .breed-image img {
    height: 240px !important;
    max-height: 240px !important;
    padding: 16px !important;
  }

  .breed-card-stacked .breed-body {
    padding: 20px 18px 24px !important;
  }

  .spec-grid {
    grid-template-columns: 1fr 1fr !important;
    gap: 8px !important;
  }

  /* FAQ */
  .faq-list {
    gap: 8px !important;
  }

  /* Gallery accordion */
  .dog-accordion-toggle {
    padding: 16px 18px !important;
  }

  .dog-accordion-full-name {
    font-size: 1rem !important;
  }

  .per-dog-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 8px !important;
  }

  /* Contact */
  .contact-cards-layout {
    grid-template-columns: 1fr !important;
  }

  .contact-card-full {
    grid-column: auto !important;
  }

  .field-grid {
    grid-template-columns: 1fr !important;
  }

  .contact-form {
    padding: 22px 18px !important;
  }

  /* Footer */
  .footer-grid {
    grid-template-columns: 1fr !important;
    gap: 24px !important;
  }

  .footer-brand {
    grid-column: auto !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
  }

  .footer-bottom {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 6px !important;
  }

  /* Section card */
  .section-card {
    width: calc(100% - 16px) !important;
    border-radius: 18px !important;
    margin: 12px auto !important;
  }

  /* Scroll top button */
  .scroll-top-btn {
    bottom: 16px !important;
    right: 12px !important;
    width: 44px !important;
    height: 44px !important;
    font-size: 18px !important;
  }

  /* Lightbox */
  .custom-lightbox-image {
    max-width: 96vw !important;
    max-height: 74vh !important;
  }

  .custom-lightbox-nav {
    width: 40px !important;
    height: 40px !important;
    font-size: 22px !important;
  }

  .custom-lightbox-nav.prev { left: 8px !important; }
  .custom-lightbox-nav.next { right: 8px !important; }
}

/* ===========================================
   MOBILE SMALL  < 480px
=========================================== */
@media (max-width: 479px) {
  .container {
    width: calc(100% - 16px);
  }

  /* Nav */
  .brand strong {
    font-size: 0.95rem !important;
  }

  .brand small {
    display: none !important;
  }

  .brand img {
    width: 44px !important;
  }

  .lang-btn {
    padding: 4px 8px !important;
    font-size: 0.72rem !important;
  }

  .lang-flag {
    width: 16px !important;
  }

  /* Hero */
  .hero-mobile-image {
    height: 240px !important;
    min-height: 240px !important;
    max-height: 240px !important;
  }

  .hero-mobile-text h1 {
    font-size: 1.5rem !important;
  }

  .hero-mobile-text .hero-text {
    font-size: 0.9rem !important;
  }

  /* Stats — 2 stupca */
  .stats-grid {
    grid-template-columns: 1fr 1fr !important;
  }

  .stats-grid article strong {
    font-size: 1.4rem !important;
  }

  /* Dog profile */
  .dog-profile-card {
    padding: 22px 14px !important;
  }

  .dog-profile-image-wrap img {
    max-height: 280px !important;
  }

  .dog-fact-row {
    grid-template-columns: 82px 1fr !important;
    padding: 8px 12px !important;
    font-size: 0.82rem !important;
  }

  .dog-profile-btn {
    width: 100% !important;
    text-align: center !important;
  }

  /* Breeds */
  .breed-card-stacked .breed-image img {
    height: 200px !important;
    max-height: 200px !important;
    padding: 12px !important;
  }

  /* Gallery */
  .per-dog-grid {
    grid-template-columns: repeat(2, 1fr) !important;
    gap: 6px !important;
  }

  /* Litters card */
  .litters-card {
    padding: 22px 18px !important;
  }

  /* Contact form */
  .contact-form {
    padding: 18px 14px !important;
  }

  /* Section card */
  .section-card {
    width: calc(100% - 12px) !important;
    border-radius: 14px !important;
  }
}

/* ===========================================
   TOUCH DEVICE HELPERS
=========================================== */
@media (hover: none) and (pointer: coarse) {
  /* Veći touch targeti */
  .btn {
    min-height: 48px !important;
    padding-top: 14px !important;
    padding-bottom: 14px !important;
  }

  .site-nav a {
    min-height: 44px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
  }

  .dog-accordion-toggle {
    min-height: 56px !important;
  }

  .gallery-box {
    cursor: pointer !important;
  }

  /* Ukloni hover efekte na touch */
  .breed-card-stacked:hover .breed-image img {
    transform: none !important;
  }

  .gallery-box:hover {
    transform: none !important;
  }

  .dog-profile-image-wrap img {
    transition: none !important;
  }
}

/* ===========================================
   PRINT
=========================================== */
@media print {
  .site-header,
  .site-nav,
  .nav-toggle,
  .lang-switcher,
  .scroll-top-btn,
  .hero-actions,
  .contact-form,
  .map-card,
  #gallery,
  .site-footer {
    display: none !important;
  }

  body {
    background: #fff !important;
    color: #000 !important;
    font-size: 11pt !important;
  }

  .section {
    page-break-inside: avoid;
    padding: 16px 0 !important;
  }

  a[href]::after {
    content: " (" attr(href) ")";
    font-size: 0.75em;
    color: #555;
  }

  a[href^="tel"]::after,
  a[href^="mailto"]::after {
    content: "";
  }
}
