/* Gymnocalycium Galerie · Pampa — WordPress content, widgets and plugin output.
   Tokens come from pampa.css (DESIGN.md). */

/* ───────── Header extras ───────── */
.brand-img { display: block; height: 42px; width: auto; }
@media (min-width: 1421px) { .menu > li > a { padding: 0 6px; } .sub-toggle { margin-left: -5px; } }
.brand-text { display: inline-block; padding: 8px 0; font: 800 20px/1.1 var(--display); color: var(--ink); }
.site-nav { display: flex; align-items: center; gap: 2px; }
.site-search { position: relative; flex: none; }
.site-search > summary {
  list-style: none; width: 44px; height: 44px; display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--pill); background: var(--ground); color: var(--ink); cursor: pointer;
}
.site-search > summary::-webkit-details-marker { display: none; }
.site-search > summary svg { width: 18px; height: 18px; }
.site-search > summary:hover, .site-search[open] > summary { background: var(--tint); color: var(--accent); }
.site-search-panel { position: absolute; right: 0; top: calc(100% + 10px); width: min(420px, 86vw); padding: 12px; background: var(--surface); border-radius: var(--r-md); box-shadow: 0 2px 6px rgba(34, 25, 43, .06), 0 18px 40px rgba(34, 25, 43, .14); z-index: 30; }
@media (max-width: 1420px) {
  .site-nav { flex-direction: column; align-items: stretch; }
  .site-search { padding: 8px 4px 4px; }
  .site-search > summary { display: none; }
  .site-search-panel { position: static; width: auto; box-shadow: none; padding: 0; }
  .site-search:not([open]) > .site-search-panel { display: block; }
}
details.site-search:not([open]) .site-search-panel { display: none; }
@media (max-width: 1420px) { details.site-search .site-search-panel { display: block !important; } }

.search-form { display: flex; gap: 8px; }
.search-form input[type="search"] { flex: 1; min-width: 0; height: 46px; padding: 0 18px; border: 1.5px solid var(--tint); border-radius: var(--pill); background: var(--surface); color: var(--ink); font: 400 16px/1 var(--text); }
.search-form input[type="search"]:focus { outline: none; border-color: var(--accent); }
.search-form button { height: 46px; padding: 0 18px; border: 0; border-radius: var(--pill); background: var(--accent); color: #fff; font: 600 15px/1 var(--text); cursor: pointer; }
.search-form button:hover { background: var(--accent-deep); }

/* ───────── Page heads ───────── */
.page-head { margin-top: var(--gutter); padding: var(--pad); }
.page-title { margin: 0; font-family: var(--display); font-weight: 700; font-size: clamp(28px, 3vw, 38px); line-height: 1.08; letter-spacing: -.015em; }
.page-desc, .page-head .lede { margin-top: 12px; color: var(--ink-2); max-width: var(--measure); }
.page-search { margin-top: 18px; max-width: 520px; }
.taxon.no-side { grid-template-columns: minmax(0, 1fr); }
.taxon .seeds figure img { width: 100%; height: auto; max-width: 150px; margin: 0 auto; aspect-ratio: 1 / 1; object-fit: contain; }
.taxon .seeds figcaption { margin-top: 8px; font-size: 13px; line-height: 1.45; color: var(--ink-2); }

/* ───────── Reading panel: the existing page markup ───────── */
.reading { margin-top: var(--gutter); }
.entry { font-size: 18px; line-height: 1.65; color: var(--ink); overflow-wrap: break-word; }
.prose-flow > *, .prose-flow > div > * { max-width: 72ch; margin-left: auto; margin-right: auto; }
.prose-flow > :first-child { margin-top: 0; }
.entry p { margin: 0 0 1.05em; }
.entry ul, .entry ol { margin: 0 auto 1.3em; padding-left: 1.2em; }
.entry li { margin: 0 0 .35em; }
.entry li::marker { color: var(--accent); }
.entry h1, .entry h2, .entry h3, .entry h4 { font-family: var(--display); font-weight: 700; line-height: 1.2; letter-spacing: -.01em; margin: 1.6em auto .5em; text-wrap: balance; }
.entry h1 { font-size: clamp(28px, 3vw, 38px); }
.entry h2 { font-size: 26px; }
.entry h3 { font-size: 18px; }
.entry h4 { font-size: 18px; }
.entry [style*="text-align: center"], .entry .has-text-align-center { text-align: left !important; }
.entry h2.green-message, .entry .green-message { font-family: var(--text); font-size: 16px; font-weight: 400; padding: 14px 18px; border-radius: var(--r-md); background: var(--ground); }
.entry h2.green-message strong { font-weight: 700; }
/* Legacy inline colours and fonts give way to the palette; links keep the accent. */
.entry [style*="color"], .entry font[color] { color: inherit !important; }
.entry [style*="font-family"], .entry font[face] { font-family: inherit !important; }
.entry [style*="background"] { background: transparent !important; }
.entry a { color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: .18em; }
.entry a:hover { color: var(--accent-deep); }
.entry a [style*="color"] { color: inherit !important; }
.entry em, .entry i { font-style: italic; }
.entry address { font-style: normal; }
.entry img { max-width: 100%; height: auto; }
.entry hr, .entry .wp-block-separator { border: 0; border-top: 1px solid var(--tint); margin: 2em auto; max-width: 72ch; }
.entry blockquote { margin: 0 auto 1.3em; padding: 16px 20px; border-radius: var(--r-md); background: var(--ground); color: var(--ink-2); }
.entry figure { margin: 0 auto 1.4em; }
.entry figcaption, .entry .wp-caption-text, .entry .wp-element-caption { margin-top: 8px; font-size: 14px; line-height: 1.5; color: var(--ink-2); text-align: left; }
.entry .wp-block-image img { border-radius: var(--r-md); }
.entry .aligncenter { margin-left: auto; margin-right: auto; text-align: center; }
.entry .alignright { float: right; margin: 4px 0 16px 24px; max-width: 45%; }
.entry .alignleft { float: left; margin: 4px 24px 16px 0; max-width: 45%; }
.entry::after { content: ""; display: table; clear: both; }
@media (max-width: 560px) { .entry .alignright, .entry .alignleft { float: none; margin: 0 auto 16px; max-width: 100%; } }

/* Photo runs inside the text keep their proportions. */
.entry .inline-series { max-width: none; margin: 1.6em 0; }
.entry .inline-series.single .shot { flex-grow: 0; }

/* Classic [gallery] output anywhere in the text. */
.entry .gallery { display: flex; flex-wrap: wrap; gap: 14px; max-width: 72ch; margin: 0 auto 1.4em; }
.entry .gallery br { display: none; }
.entry .gallery-item { margin: 0; flex: 0 1 180px; max-width: none !important; width: auto !important; }
.entry .gallery-item img { border: 0 !important; border-radius: var(--r-sm); }

/* Tables: TablePress, Ninja Tables, plain tables. */
.entry table { width: 100%; border-collapse: collapse; font-size: 15.5px; line-height: 1.4; }
.entry th { text-align: left; padding: 12px 14px; font: 700 14px/1.2 var(--display); color: var(--accent); background: var(--ground); }
.entry td { padding: 8px 14px; vertical-align: top; border: 0; }
.entry tbody tr:nth-child(even) td { background: var(--ground); }
.entry .footable_parent, .entry .ninja_table_wrapper, .entry .tablepress-scroll-wrapper, .entry .dataTables_wrapper { max-width: 1120px !important; margin: 10px auto 44px !important; overflow-x: auto; border-radius: var(--r-md); }
.entry .ninja_footable.ui.table, .entry table.tablepress { border: 0 !important; border-radius: 0 !important; box-shadow: none !important; background: transparent !important; font-family: var(--text) !important; }
.entry .ninja_footable.ui.table thead th, .entry table.tablepress thead th { background: var(--ground) !important; color: var(--accent) !important; font: 700 14px/1.2 var(--display) !important; border: 0 !important; }
.entry .ninja_footable.ui.table td, .entry table.tablepress td { border: 0 !important; color: var(--ink) !important; }
.entry .ninja_footable.ui.table tbody tr:nth-child(odd) td, .entry table.tablepress tbody tr:nth-child(odd) td { background: var(--surface) !important; }
.entry .ninja_footable.ui.table tbody tr:nth-child(even) td, .entry table.tablepress tbody tr:nth-child(even) td { background: var(--ground) !important; }
.entry .ninja_footable.ui.table tbody td:first-child { font-weight: 700; font-variant-numeric: tabular-nums; }
@media (max-width: 760px) {
  .entry .footable_parent, .entry .ninja_table_wrapper { -webkit-mask-image: linear-gradient(90deg, var(--ink) calc(100% - 40px), transparent); mask-image: linear-gradient(90deg, var(--ink) calc(100% - 40px), transparent); padding-right: 40px; }
  .entry .ninja_footable.ui.table th:first-child, .entry .ninja_footable.ui.table td:first-child { position: sticky; left: 0; z-index: 1; box-shadow: 1px 0 0 var(--tint); }
}

/* Forms in pages: Contact Form 7, the guestbook (Livre d'Or), comments. */
.entry input[type="text"], .entry input[type="email"], .entry input[type="url"], .entry input[type="tel"], .entry input[type="number"], .entry textarea, .entry select {
  width: 100%; max-width: 560px; padding: 12px 16px; border: 1.5px solid var(--tint); border-radius: var(--r-sm); background: var(--surface); color: var(--ink); font: 400 16px/1.4 var(--text);
}
.entry input:focus, .entry textarea:focus, .entry select:focus { outline: none; border-color: var(--accent); }
.entry input[type="submit"], .entry button[type="submit"], .entry .wpcf7-submit, .entry .button {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 22px; border: 0; border-radius: var(--pill); background: var(--accent); color: #fff; font: 600 16px/1 var(--text); cursor: pointer;
}
.entry input[type="submit"]:hover, .entry button[type="submit"]:hover, .entry .wpcf7-submit:hover { background: var(--accent-deep); }
.entry label { font-weight: 600; font-size: 15px; }

/* ───────── Lists (tags, categories, search) ───────── */
.list-grid { list-style: none; margin: var(--gutter) 0 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: var(--gutter); }
.list-item { display: flex; flex-direction: column; gap: 10px; height: 100%; padding: 10px 10px 16px; border-radius: var(--r-lg); background: var(--surface); color: var(--ink); text-decoration: none; }
.list-item .ph { display: block; overflow: hidden; border-radius: var(--r-md); background: var(--photo-well); aspect-ratio: 4 / 3; }
.list-item .ph img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease-out); }
.list-item:hover .ph img { transform: scale(1.03); }
.list-item .name { padding: 0 6px; font-style: italic; font-weight: 500; line-height: 1.35; }
.list-item:hover .name { color: var(--accent); }
.pager, .pagination { margin: 28px 0 0; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: 6px; }
.pagination .page-numbers { min-width: 44px; height: 44px; padding: 0 12px; display: inline-flex; align-items: center; justify-content: center; border-radius: var(--pill); background: var(--surface); color: var(--ink); text-decoration: none; font-weight: 600; }
.pagination .page-numbers.current, .pagination a.page-numbers:hover { background: var(--accent); color: #fff; }

/* ───────── Footer widgets (province tags) ───────── */
.foot-widgets + .foot-widgets { margin-top: 28px; }
.foot-widgets .widget + .widget { margin-top: 28px; }
.foot-widgets a { color: var(--band-ink); }
.foot-widgets .widget-simpletags a, .foot-widgets .tagcloud a, .foot-widgets .st-tag-cloud a {
  display: inline-flex; align-items: center; min-height: 40px; margin: 0 4px 8px 0; padding: 0 16px; border-radius: var(--pill);
  background: var(--band-2); color: var(--band-ink) !important; font-size: 14px !important; line-height: 1.2; text-decoration: none; transition: background-color .2s var(--ease-out);
}
.foot-widgets .widget-simpletags a:hover, .foot-widgets .tagcloud a:hover, .foot-widgets .st-tag-cloud a:hover { background: var(--accent); color: #fff !important; }
.foot-widgets ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0; }
.foot-widgets li { margin: 0; }

/* ───────── WordPress core helpers ───────── */
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.page-links { margin-top: 20px; }
.bypostauthor { }
.wp-caption { max-width: 100%; }
.sticky { }
.gallery-caption { }
