/* Reusable components. */

/* Visible to screen readers, not to sighted users. Used by the checkout labels,
   which must exist because i18n.js rewrites placeholders at runtime. */
.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Inline checkout validation message (replaces a blocking alert()). */
.checkout-error {
    display: block;
    color: #C62828;
    font-size: 14px;
    margin-top: 16px;
}
.checkout-error:empty {
    display: none;
}

/* Placeholder for a database-backed section that has nothing to show yet. */
.placeholder-block {
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    text-align: center;
    padding: 48px 24px;
    border: 1px dashed var(--color-border);
    border-radius: var(--radius-md);
}

.placeholder-title {
    font-size: 18px;
    font-weight: 700;
}

.placeholder-desc {
    font-size: 14px;
    color: var(--color-text-secondary);
    max-width: 420px;
}

/* Real rows carry 80px of vertical padding; the products collection itself has
   no margin, so an empty state needs its own space above and below. */
body.page-products .editorial-list > .placeholder-block {
    margin: 80px 0;
}

/* Grids collapse to a single full-width placeholder row. */
body.page-index .news-grid > .placeholder-block,
body.page-news .news-grid > .placeholder-block {
    grid-column: 1 / -1;
}

/* The featured card is a flex row, so the placeholder fills it. */
body.page-news .featured-card > .placeholder-block {
    flex: 1;
    min-height: 340px;
    border-radius: var(--radius-md);
}

body.page-index .hero,
body.page-about .hero,
body.page-news .hero,
body.page-products .hero,
body.page-story .hero,
body.page-venue .hero {
    padding: 80px 0;
    text-align: center;
    background-color: var(--color-pastel-green);
}

body.page-privacy .hero,
body.page-terms .hero {
    padding: 64px 0;
    text-align: center;
    background-color: var(--color-pastel-green);
}

body.page-404 .hero {
    padding: 100px 0;
    text-align: center;
    background-color: var(--color-pastel-green);
}

body.page-404 .hero-inner,
body.page-index .hero-inner,
body.page-about .hero-inner,
body.page-news .hero-inner,
body.page-products .hero-inner,
body.page-venue .hero-inner,
body.page-privacy .hero-inner,
body.page-terms .hero-inner {
    max-width: 650px;
    margin: 0 auto;
    padding: 0 24px;
}

body.page-story .hero-inner {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 24px;
}

body.page-index h1,
body.page-about h1,
body.page-news h1,
body.page-products h1,
body.page-venue h1 {
    font-size: 48px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -1.5px;
    line-height: 1.1;
}

body.page-privacy h1,
body.page-terms h1 {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -1.5px;
    line-height: 1.1;
}

body.page-story h1 {
    font-size: 44px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -1.5px;
    line-height: 1.1;
}

body.page-cart h1 {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 40px;
    letter-spacing: -1px;
}

body.page-404 .hero p,
body.page-index .hero p,
body.page-products .hero p,
body.page-venue .hero p {
    color: var(--color-text-secondary);
    font-size: 18px;
    margin-bottom: 36px;
    line-height: 1.6;
}

body.page-about .hero p,
body.page-news .hero p {
    color: var(--color-text-secondary);
    font-size: 18px;
    margin-bottom: 0;
    line-height: 1.6;
}

body.page-privacy .hero p,
body.page-terms .hero p {
    color: var(--color-text-secondary);
    font-size: 16px;
    line-height: 1.6;
}

body.page-404 .btn-primary,
body.page-index .btn-primary,
body.page-products .btn-primary {
    background: var(--color-black);
    color: var(--color-white);
    border: none;
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-block;
    text-decoration: none;
}

body.page-news .btn-primary,
body.page-story .btn-primary {
    background: var(--color-black);
    color: var(--color-white);
    border: none;
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-block;
    text-decoration: none;
    font-family: var(--font-main);
}

body.page-venue .btn-primary,
body.page-cart .btn-primary {
    background: var(--color-black);
    color: var(--color-white);
    border: none;
    padding: 14px 28px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 15px;
    cursor: pointer;
    transition: var(--transition);
    display: inline-block;
    text-decoration: none;
    text-align: center;
    font-family: var(--font-main);
}

body.page-404 .btn-primary:hover,
body.page-index .btn-primary:hover,
body.page-news .btn-primary:hover,
body.page-products .btn-primary:hover,
body.page-story .btn-primary:hover,
body.page-venue .btn-primary:hover,
body.page-cart .btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* Section header. The centered form is a separate component (.section-header--center)
   because about.html used the same class name for a block-level centered heading. */
.section-header {
    margin-bottom: 32px;
    display: flex;
    align-items: center;
    gap: 16px;
}
.section-header--center {
    margin-bottom: 60px;
    text-align: center;
    display: block;
}

/* Split header (index.html "Farm Products" + "Seasonal Selection"). Was an
   inline style, which pinned it to one flex row and jammed on narrow screens. */
.section-header--split {
    max-width: var(--container-width);
    margin: 80px auto 40px;
    padding: 0 24px 16px;
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 16px;
    border-bottom: 2px solid var(--color-black);
}
.section-header--split .section-title {
    font-size: 36px;
    font-weight: 700;
}
.section-header--split > span {
    font-weight: 600;
    font-size: 14px;
    color: var(--color-text-secondary);
    white-space: nowrap;
}

body.page-index .section-title,
body.page-news .section-title {
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

body.page-about .section-title {
    font-size: 40px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -1px;
}

body.page-venue .section-title {
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 40px;
    letter-spacing: -1px;
}

body.page-index .bento-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    grid-auto-rows: 240px;
    gap: 20px;
}

body.page-index .card {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    padding: 24px;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
    background: var(--color-white);
}

body.page-index .card-large {
    grid-column: span 4;
    grid-row: span 2;
}

body.page-index .card-tall {
    grid-column: span 2;
    grid-row: span 2;
}

body.page-index .card-wide {
    grid-column: span 4;
    grid-row: span 1;
}

body.page-index .card-standard {
    grid-column: span 2;
    grid-row: span 1;
}

body.page-index .card-image-box {
    background: var(--color-pastel-green);
    flex-grow: 1;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
}

body.page-index .card-image-box svg {
    color: var(--color-green-accent);
    opacity: 0.3;
}

body.page-index .tag,
body.page-products .tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    display: block;
}

body.page-news .tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
    display: block;
}

body.page-story .tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 16px;
    display: block;
}

body.page-venue .tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 20px;
    display: inline-block;
}

body.page-index .card-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 4px;
}

body.page-index .card-price {
    font-size: 14px;
    color: var(--color-text-secondary);
}

body.page-index .card-desc {
    font-size: 14px;
    color: var(--color-text-secondary);
}

body.page-index .news-grid,
body.page-news .news-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

body.page-index .news-card,
body.page-news .news-card {
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    background: var(--color-white);
    transition: var(--transition);
}

body.page-index .news-card-image,
body.page-news .news-card-image {
    aspect-ratio: 16/9;
    background: var(--color-pastel-green);
    display: flex;
    align-items: center;
    justify-content: center;
}

body.page-index .news-card-image svg,
body.page-news .news-card-image svg {
    color: var(--color-green-accent);
    opacity: 0.3;
}

body.page-index .news-card-content,
body.page-news .news-card-content {
    padding: 20px;
}

body.page-index .news-card-date,
body.page-news .news-card-date {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--color-green-accent);
    margin-bottom: 8px;
}

body.page-index .news-card-title,
body.page-news .news-card-title {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
    line-height: 1.3;
}

body.page-index .news-card-excerpt,
body.page-news .news-card-excerpt {
    font-size: 14px;
    color: var(--color-text-secondary);
    line-height: 1.5;
}

body.page-index .feature-list {
    list-style: none;
    margin-top: 24px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

body.page-venue .feature-list {
    flex: 1;
    list-style: none;
    display: grid;
    gap: 16px;
}

body.page-index .feature-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--color-green-accent);
    font-weight: 600;
}

body.page-venue .feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 15px;
    color: var(--color-green-accent);
    font-weight: 600;
}

body.page-index .feature-item svg {
    width: 16px;
    height: 16px;
}

body.page-venue .feature-item svg {
    width: 18px;
    height: 18px;
}

body.page-index .status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(216, 125, 74, 0.1);
    color: var(--color-orange-accent);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 16px;
}

body.page-index [dir="rtl"] .trustpilot-reviews {
    text-align: right;
}

body.page-news .featured-card {
    display: flex;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    overflow: hidden;
    background: var(--color-white);
    transition: var(--transition);
}

body.page-news .featured-media {
    flex: 1.4;
    background: var(--color-pastel-green);
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 340px;
}

body.page-news .featured-media svg {
    color: var(--color-green-accent);
    opacity: 0.3;
}

body.page-news .featured-content {
    flex: 1;
    padding: 48px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

body.page-news .featured-date {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--color-green-accent);
    margin-bottom: 12px;
}

body.page-news .featured-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 16px;
    letter-spacing: -1px;
    line-height: 1.15;
}

body.page-news .featured-excerpt {
    font-size: 16px;
    color: var(--color-text-secondary);
    line-height: 1.6;
    margin-bottom: 32px;
}

body.page-news .social-container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 24px;
    text-align: center;
}

body.page-news .social-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: -1px;
}

body.page-news .social-text {
    color: var(--color-text-secondary);
    font-size: 16px;
    line-height: 1.6;
    max-width: 480px;
    margin: 0 auto;
}

body.page-news .social-links {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 32px;
}

body.page-news .social-link {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--color-white);
    color: var(--color-black);
    border: 1px solid var(--color-border);
    transition: var(--transition);
}

body.page-news .social-link:hover {
    background: var(--color-green-accent);
    border-color: var(--color-green-accent);
    color: var(--color-white);
    transform: translateY(-2px);
}

body.page-news .social-link svg {
    width: 22px;
    height: 22px;
}

body.page-story .hero-meta {
    color: var(--color-text-secondary);
    font-size: 14px;
    font-weight: 500;
}

body.page-cart [dir="rtl"] .item-price {
    text-align: left;
}

body.page-privacy [dir="rtl"] .legal-section ul,
body.page-terms [dir="rtl"] .legal-section ul {
    padding-left: 0;
    padding-right: 20px;
}
