/*
Theme Name: Ogrodysta
Author: 
Version: 
Text Domain: ogrodysta
*/


/* Zmienne */

:root {
  --green:       #0B3D2E;
  --green-mid:   #4a6f46;
  --green-hover: #356034;
  --light:       #ffffff;
  --bg:          #f4f7f3;
  --text:        #2f3e2e;
}


/* Reset i baza */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html  { scroll-behavior: smooth; }
body  { font-family: 'Poppins', sans-serif; background: var(--bg); color: var(--text); line-height: 1.65; }
img, video, audio { max-width: 100%; display: block; height: auto; }


/* Header / Hero */

.site-header {
  background: var(--green);
  text-align: center;
  padding: 90px 20px;
  color: var(--light);
}

/* the_custom_logo() opakowuje logo w <a> */
.site-logo { margin-bottom: 25px; }
.site-logo--left  { text-align: left; }
.site-logo--center { text-align: center; }
.site-logo--left  .custom-logo-link { display: inline-block; }
.site-logo--center .custom-logo-link { display: inline-block; }
.site-header .custom-logo {
  width: 160px; height: 160px;
  border-radius: 50%; object-fit: cover;
}

.site-header .site-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(2rem, 6vw, 3.2rem);
  font-weight: 700;
}
.site-header .site-tagline {
  font-size: clamp(1rem, 3.2vw, 1.3rem);
  margin: 14px 0;
  font-weight: 500;
}
.site-header .site-slogan {
  font-size: clamp(0.95rem, 3vw, 1.1rem);
  margin: 6px 0 0;
  opacity: .85;
}





/* Nawigacja */

.header-nav {
  margin-top: 30px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
}
.header-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: center;
  list-style: none;
  margin: 0; padding: 0;
}
.header-nav li { list-style: none; margin: 0; padding: 0; }
.header-nav a {
  display: block;
  padding: 11px 22px;
  background: var(--green-mid);
  color: #fff;
  border-radius: 6px;
  font-weight: 500;
  font-size: 1rem;
  text-decoration: none;
  transition: background .18s;
}
.header-nav a:hover { background: var(--green-hover); }


/* Treść strony */

.page-content {
  max-width: 1000px;
  margin: 0 auto;
  padding: 0 16px 60px;
}


/* Sekcje – main.js opakowuje bloki między H2 w .og-section */

.og-section {
  background: rgba(255,255,255,.92);
  border-radius: 12px;
  box-shadow: 0 0 20px rgba(0,0,0,.05);
  padding: clamp(28px,4vw,45px) clamp(18px,3vw,40px);
  margin: 50px 0;
  scroll-margin-top: 16px;
}

.og-section h2 {
  font-family: 'Playfair Display', serif;
  font-size: clamp(1.6rem, 4vw, 2rem);
  color: var(--text);
  padding-bottom: 12px;
  margin-bottom: 20px;
  border-bottom: 2px solid var(--green-mid);
}

/* typografia */
.og-section p            { margin-bottom: 14px; font-size: 1.03em; line-height: 1.75; }
.og-section p:last-child { margin-bottom: 0; }
.og-section strong,
.og-section b            { color: var(--green); }
.og-section h3           { font-size: 1.15em; color: var(--green); margin: 16px 0 8px; }
.og-section h4           { font-size: 1em; font-weight: 600; margin: 12px 0 6px; }
.og-section a            { color: var(--green-mid); font-weight: 500; }
.og-section ul,
.og-section ol           { margin: 10px 0 14px 20px; }
.og-section li           { margin-bottom: 6px; font-size: 1.02em; }

/* zdjęcia */
.og-section img        { border-radius: 10px; box-shadow: 0 2px 10px rgba(0,0,0,.1); }
.og-section figure     { margin: 16px 0; }
.og-section figcaption { font-size: .85em; color: #888; margin-top: 6px; text-align: center; }

/* reset marginesów bloków żeby nie wchodziły na padding sekcji */
.og-section > *     { margin-top: 0; margin-bottom: 0; }
.og-section > * + * { margin-top: 16px; }
.og-section .wp-block-heading { margin-top: 0 !important; }


/* Bloki Gutenberg */

/* kolumny */
.og-section .wp-block-columns {
  display: flex !important;
  flex-wrap: wrap;
  gap: 28px;
  align-items: flex-start;
  margin: 0 !important;
}
.og-section .wp-block-column     { flex: 1 1 260px; min-width: 0; }
.og-section .wp-block-column img { width: 100%; border-radius: 10px; box-shadow: 0 2px 10px rgba(0,0,0,.12); }

/* galeria */
/* galeria – grid na samym ul, nie nadpisujemy figure/a żeby wtyczki lightbox działały */
.og-section .wp-block-gallery {
  display: grid !important;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)) !important;
  gap: 14px !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}
.og-section .wp-block-gallery li.wp-block-image { margin: 0 !important; }
.og-section .wp-block-gallery figure           { margin: 0 !important; }
.og-section .wp-block-gallery a                { display: block; }
.og-section .wp-block-gallery img {
  width: 100%;
  aspect-ratio: 4/3;
  object-fit: cover;
  border-radius: 8px;
  box-shadow: none;
  display: block;
}

/* lista – dwie kolumny na szerszych ekranach */
.og-section .wp-block-list,
.og-section ul.wp-block-list {
  list-style: disc inside;
  columns: 2 220px;
  gap: 16px;
  margin-left: 0;
}

/* audio */
.og-section .wp-block-audio,
.og-section audio { width: 100%; margin: 8px 0 20px; }

/* group – pełna szerokość */
.og-section .wp-block-group { width: 100%; }


/* Stopka */

.site-footer {
  background: var(--green);
  color: var(--light);
  text-align: center;
  padding: 22px;
  font-size: .95em;
}
.site-footer a { color: var(--light); text-decoration: none; }


/* Responsywność */

@media (max-width: 900px) {
  .site-header { padding: 72px 18px; }
  .header-nav, .header-nav ul { gap: 8px; }
  .og-section { margin: 36px 0; }
}

@media (max-width: 680px) {
  .og-section .wp-block-columns { flex-direction: column; }
  .og-section .wp-block-list,
  .og-section ul.wp-block-list  { columns: 1; }
}

@media (max-width: 480px) {
  .site-header { padding: 52px 14px; }
  .site-header .custom-logo { width: 120px; height: 120px; }
  .og-section { margin: 22px 0; padding: 24px 14px; }

  .header-nav {
    max-width: 360px;
    margin-left: auto;
    margin-right: auto;
  }

  /* siatka 6-kolumnowa: domyślnie każde li zajmuje 3 (czyli pół szerokości) */
  .header-nav ul {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
  }
  .header-nav li         { grid-column: span 3; }
  .header-nav li.full    { grid-column: span 6; }  /* pełna szerokość */
  .header-nav li.third   { grid-column: span 2; }  /* 3 w rzędzie */

  .header-nav a { text-align: center; padding: 11px 6px; font-size: .86rem; }
}
