/*
    Theme Name: Inksea
    Theme URI: https://inksea.pl
    Author: Marta Kluka
    Author URI: https://martakluka.pl
    Description: Child theme of Astra for managing ink database with custom post types and taxonomies.
    Version: 1.0
    Template: astra
    License: GNU General Public License v2 or later
    License URI: https://www.gnu.org/licenses/gpl-2.0.html
    Text Domain: inksea
*/


h1 {
    text-align: center;
}

h2 {
    border-top: 1px solid #ddd;
    border-bottom: 1px solid #ddd;
    padding: 5px;
    text-align: center;
    margin: 1rem 0;
}

.shop-thumbnail img,
.brand-thumbnail img,
.ink-thumbnail img {
    height: auto;
    display: block;
    margin: 0 auto;
}


.ink-images figure {
    margin-bottom: 2rem;
}

.ink-images figure img {
  height: auto;
  display: block;
  margin: 0 auto;
}

.ink-images figcaption {
    text-align: center;
    color: #666;
}

.grid-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  margin: 2rem 0;
}

.grid-item {
  text-align: center;
  border: 1px solid #ddd;   /* subtle border */
  border-radius: 6px;       /* rounded corners */
  padding: 0.75rem;         /* small padding around content */
}

.grid-item img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  background-color: #f9f9f9; /* subtle background behind image */
}

.grid-item figcaption {
  margin-top: 0.5rem;
  font-size: 0.95rem;
  line-height: 1.4;
}

/* Tablet view: 2 columns */
@media (max-width: 900px) {
  .grid-list {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Mobile view: 1 column */
@media (max-width: 600px) {
  .grid-list {
    grid-template-columns: 1fr;
  }
}

.ink-sections {
  display: flex;
  gap: 2rem; /* spacing between sections */
  align-items: flex-start;
}

.ink-sections section {
  flex: 1; /* each section takes equal width */
}

/* Mobile: stack vertically */
@media (max-width: 600px) {
  .ink-sections {
    flex-direction: column;
  }
}

.taxonomy-children {
  margin: 1.5rem 0;
}

.taxonomy-children ul {
  list-style: none;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-left: 0;
}

.taxonomy-children li a {
  padding: 0.25rem 0.5rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  text-decoration: none;
  background-color: #f9f9f9;
}

.taxonomy-children li a:hover {
  background-color: #eee;
}


#spinner {
  border: 4px solid #f3f3f3;
  border-top: 4px solid #333;
  border-radius: 50%;
  width: 24px;
  height: 24px;
  animation: spin 1s linear infinite;
  margin: 0.5rem auto;
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }

  100% {
    transform: rotate(360deg);
  }
}

.load-more-wrapper {
  text-align: center;
  margin-top: 2rem;
}

/* Container for each brand+ink pair */
.compare-row {
  display: flex;
  flex-wrap: wrap;
  /* allows wrapping on small screens */
  gap: 1rem;
  /* spacing between selects */
  margin-bottom: 1rem;
}

/* Labels inline on large screens */
.compare-row label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Selects should not shrink too small */
.compare-row select {
  min-width: 180px;
}

/* On small screens, stack vertically */
@media (max-width: 600px) {
  .compare-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .compare-row label {
    width: 100%;
  }

  .compare-row select {
    width: 100%;
  }
}