/*
Theme Name: HolisticWow HU
Theme URI: https://holisticwow.hu
Author: HolisticWow
Description: A minimalist, speedy theme for autoritative herbal content.
Version: 1.1
Text Domain: holisticwow
*/

:root {
    --primary-green: #2F5233;
    --secondary-green: #5C7A60;
    --accent-gold: #D4AF37;
    --bg-cream: #F9F7F2;
    --text-dark: #333;
    --text-light: #666;
    --white: #ffffff;
}

body {
    margin: 0;
    padding: 0;
    background-color: var(--bg-cream);
    font-family: 'Lato', sans-serif;
    color: var(--text-dark);
    line-height: 1.8;
    text-rendering: optimizeLegibility;
}

h1,
h2,
h3,
h4 {
    font-family: 'Playfair Display', serif;
    color: var(--primary-green);
    margin-top: 0;
    font-synthesis-weight: none;
    font-synthesis-style: none;
}

a {
    color: var(--primary-green);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

.article a,
.solution-article a {
    text-decoration: underline;
    text-underline-offset: 3px;
}

.article a:hover,
.solution-article a:hover {
    text-decoration-thickness: 2px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Nav */
nav {
    padding: 20px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 90px;
}

.logo {
    display: flex;
    align-items: center;
    width: 180px;
    min-width: 180px;
    height: 50px;
}

.logo img {
    width: 180px;
    height: 50px;
    display: block;
    aspect-ratio: 180 / 50;
}

.menu {
    display: flex;
    gap: 20px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.menu li {
    margin: 0;
}

.menu li a {
    color: var(--primary-green);
    text-decoration: none;
    font-weight: 400;
    transition: color 0.2s ease;
}

.menu li a:hover {
    color: var(--accent-gold);
    text-decoration: none;
}

.nav-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.search-form {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(47, 82, 51, 0.12);
    border-radius: 999px;
    padding: 8px 10px 8px 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.06);
    backdrop-filter: blur(4px);
}

.search-field {
    border: none;
    background: transparent;
    outline: none;
    min-width: 200px;
    font-size: 14px;
    color: var(--text-dark);
}

.search-field::placeholder {
    color: var(--text-light);
}

.search-submit {
    background: var(--primary-green);
    color: #fff;
    border: none;
    border-radius: 999px;
    padding: 8px 16px;
    font-weight: 700;
    letter-spacing: 0.2px;
    cursor: pointer;
    transition: background 0.2s ease, transform 0.2s ease;
}

.search-submit:hover {
    background: var(--secondary-green);
    transform: translateY(-1px);
}

.screen-reader-text {
    position: absolute;
    clip: rect(1px, 1px, 1px, 1px);
    padding: 0;
    border: 0;
    height: 1px;
    width: 1px;
    overflow: hidden;
}

/* Cards */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 30px;
}

.herb-card {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid rgba(0, 0, 0, 0.04);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.herb-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 14px 28px rgba(0, 0, 0, 0.07);
}

.herb-thumb {
    display: block;
}

.herb-thumb img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: 8px;
    display: block;
}

.herb-card-title {
    margin-top: 15px;
    margin-bottom: 8px;
}

.herb-card-title a {
    color: var(--primary-green);
}

.herb-excerpt {
    font-size: 0.95em;
    color: var(--text-light);
}

/* Pills & buttons */
.pill {
    display: inline-block;
    padding: 6px 12px;
    background: rgba(212, 175, 55, 0.12);
    color: var(--primary-green);
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 999px;
    font-size: 12px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

.button {
    display: inline-block;
    padding: 12px 18px;
    background: var(--primary-green);
    color: #fff;
    border-radius: 10px;
    font-weight: 700;
    letter-spacing: 0.2px;
    border: 1px solid var(--primary-green);
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.button:hover {
    background: var(--secondary-green);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.no-results {
    background: #fff;
    border-radius: 14px;
    padding: 40px;
    text-align: center;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
}

/* Search hero */
.search-hero {
    padding: 50px 0 20px;
}

.search-hero-inner {
    background: linear-gradient(135deg, rgba(47, 82, 51, 0.06), rgba(212, 175, 55, 0.12));
    border: 1px solid rgba(47, 82, 51, 0.1);
    border-radius: 18px;
    padding: 30px;
    box-shadow: 0 16px 32px rgba(0, 0, 0, 0.08);
}

.search-hero h1 {
    margin: 10px 0;
    font-size: 34px;
}

.search-meta {
    margin: 0;
    color: var(--text-light);
}

.herb-warning {
    background: #fff;
    border: 1px solid rgba(192, 57, 43, 0.18);
    border-left: 3px solid #c0392b;
    border-radius: 4px;
    padding: 12px 18px;
    font-size: 18px;
    color: #5a1c1c;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.herb-warning strong {
    display: block;
    color: #7f1f1f;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 6px;
}

/* Sources box (collapsible) */
.sources-box {
    border: 1px solid rgba(47, 82, 51, 0.12);
    border-left: 3px solid var(--accent-gold);
    border-radius: 4px;
    background: #fff;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
    margin-top: 30px;
    overflow: hidden;
}

.sources-box summary {
    padding: 12px 16px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-size: 12px;
    color: var(--text-dark);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}

.sources-box summary::marker {
    content: "";
}

.sources-box summary::before {
    content: "▸";
    font-size: 12px;
    color: var(--primary-green);
    transition: transform 0.2s ease;
}

.sources-box[open] summary::before {
    transform: rotate(90deg);
}

.sources-box .sources-content {
    padding: 0 16px 16px 16px;
}

.sources-box ol,
.sources-box ul {
    margin: 0;
    padding-left: 20px;
}

.sources-box li {
    margin: 6px 0;
    font-size: 16px;
}

.source-marker {
    display: inline-block;
    white-space: nowrap;
    line-height: 1;
}

.source-marker a {
    text-decoration: none;
    color: var(--primary-green);
    font-weight: 700;
    font-size: 12px;
    vertical-align: super;
    margin-left: 3px;
}

/* Hero Herb */
.hero {
    display: grid;
    grid-template-columns: 1fr 1fr;
    align-items: center;
    gap: 40px;
    padding: 60px 0;
}

.hero-text h1 {
    font-size: 56px;
    margin-bottom: 10px;
    line-height: 1.1;
    min-height: 1.2em;
}

.latin-name {
    font-family: 'Playfair Display', serif;
    font-style: italic;
    color: #8a6a00;
    font-weight: 400;
    font-size: 24px;
    margin-bottom: 30px;
    display: block;
    min-height: 1.2em;
}

.hero-text h1 .latin-name {
    margin: 6px 0 0;
    font-size: 26px;
}

.hero-image {
    background-color: #e0e0e0;
    /* Placeholder color */
    width: 100%;
    height: 500px;
    border-radius: 200px 200px 0 0;
    object-fit: cover;
    position: relative;
    aspect-ratio: 1200 / 628;
}

/* Quick Facts Badge */
.badge-grid {
    display: flex;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.badge {
    background: #fff;
    padding: 10px 20px;
    border-left: 3px solid var(--accent-gold);
    font-size: 14px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.badge strong {
    display: block;
    color: var(--text-light);
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Content Layout */
.content-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 60px;
    padding: 60px 0;
}

/* Solution (Megoldas) pages */
.solution-hero {
    padding: 50px 0 30px;
    background: linear-gradient(140deg, rgba(47, 82, 51, 0.06), rgba(212, 175, 55, 0.08));
    border-bottom: 1px solid rgba(47, 82, 51, 0.08);
}

.solution-hero-inner {
    display: grid;
    grid-template-columns: minmax(0, 1.2fr) minmax(0, 0.8fr);
    gap: 30px;
    align-items: center;
}

.solution-hero-text h1 {
    font-size: 44px;
    margin: 10px 0 12px;
    line-height: 1.2;
}

.solution-lead p {
    margin: 0;
    font-size: 1.1rem;
    color: var(--text-light);
}

.solution-hero-card {
    background: var(--white);
    border-radius: 16px;
    padding: 24px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.08);
    text-align: center;
}

.solution-meta {
    text-transform: uppercase;
    letter-spacing: 1px;
    font-size: 12px;
    color: var(--text-light);
    margin: 0 0 8px;
}

.solution-count {
    font-size: 40px;
    font-weight: 700;
    color: var(--primary-green);
    margin-bottom: 14px;
}

.solution-body {
    padding: 40px 0 20px;
}

.solution-layout {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
    gap: 40px;
    align-items: start;
}

.solution-article p,
.solution-article ul,
.solution-article ol {
    font-size: 18px;
}

.solution-article h2 {
    font-size: 30px;
    margin-top: 36px;
    border-bottom: 1px solid rgba(212, 175, 55, 0.5);
    padding-bottom: 8px;
}

.solution-article table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.solution-article th,
.solution-article td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    text-align: left;
}

.solution-article th {
    background: rgba(47, 82, 51, 0.08);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--primary-green);
}

.solution-aside {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.solution-box {
    background: var(--white);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 16px;
    padding: 22px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.06);
}

.solution-box.subtle {
    background: rgba(47, 82, 51, 0.06);
    border-color: rgba(47, 82, 51, 0.1);
}

.solution-box h3 {
    margin-bottom: 10px;
}

.solution-herbs {
    padding: 20px 0 60px;
}

.solution-section-head {
    margin-bottom: 24px;
}

.solution-section-head h2 {
    font-size: 32px;
    margin-bottom: 6px;
}

.solution-section-head p {
    color: var(--text-light);
    margin: 0;
}

.solution-empty {
    background: var(--white);
    border: 1px dashed rgba(47, 82, 51, 0.2);
    border-radius: 14px;
    padding: 24px;
    color: var(--text-light);
}

@media (max-width: 768px) {
    .content-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        grid-template-columns: 1fr;
    }

    .solution-hero-inner,
    .solution-layout {
        grid-template-columns: 1fr;
    }

    .solution-hero {
        padding-top: 40px;
    }

    .solution-hero-text h1 {
        font-size: 34px;
    }

    nav {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .menu {
        flex-wrap: wrap;
    }

    .nav-right {
        width: 100%;
        gap: 12px;
        justify-content: space-between;
        flex-wrap: wrap;
    }

    .search-form {
        width: 100%;
    }

    .search-field {
        min-width: 0;
        width: 100%;
    }
}

.article p {
    margin-bottom: 25px;
    font-size: 18px;
}

.article h2 {
    font-size: 32px;
    border-bottom: 1px solid var(--accent-gold);
    padding-bottom: 10px;
    margin-top: 40px;
}

.article ul {
    margin-bottom: 25px;
    font-size: 18px;
}

.article table {
    width: 100%;
    border-collapse: collapse;
    margin: 24px 0;
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.06);
}

.article th,
.article td {
    padding: 12px 14px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    text-align: left;
}

.article th {
    background: rgba(47, 82, 51, 0.08);
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--primary-green);
}

.article a[href*="/megoldas/"],
.article a[href*="/megoldasok/"] {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(47, 82, 51, 0.08);
    border: 1px solid rgba(47, 82, 51, 0.2);
    font-weight: 700;
    text-decoration: none;
}

.article a[href*="/megoldas/"]:hover,
.article a[href*="/megoldasok/"]:hover {
    background: rgba(47, 82, 51, 0.14);
    text-decoration: none;
}

.tip-box {
    background: linear-gradient(135deg, rgba(47, 82, 51, 0.08), rgba(212, 175, 55, 0.12));
    border: 1px solid rgba(47, 82, 51, 0.18);
    border-left: 6px solid var(--primary-green);
    border-radius: 14px;
    padding: 18px 20px;
    margin: 26px 0 30px;
    box-shadow: 0 16px 30px rgba(47, 82, 51, 0.12);
}

.tip-title {
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    font-size: 12px;
    color: var(--primary-green);
    margin-bottom: 10px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.tip-title::before {
    content: "✳";
    color: var(--accent-gold);
    font-size: 14px;
}

.tip-box p {
    margin: 10px 0 0;
}

.tip-box strong {
    color: var(--primary-green);
}

.sidebar-box {
    background: var(--white);
    padding: 30px;
    border: 1px solid #eee;
    margin-bottom: 30px;
}

.sidebar-title {
    font-size: 20px;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--bg-cream);
    padding-bottom: 10px;
}

/* Tudtad Box Specifics */
.box-green .sidebar-title,
.sidebar-box[style*="background-color"] .sidebar-title {
    color: #fff !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
}

.usage-list {
    list-style: none;
    padding: 0;
}

.usage-list li {
    margin-bottom: 20px;
    display: flex;
    align-items: flex-start;
    gap: 15px;
    /* Replaces margin-right on icon */
}

/* Explicitly remove any legacy or inherited ::before content (e.g. herbs) */
.usage-list li::before {
    content: none !important;
    display: none !important;
}

/* 
   We will pass specific icons directly in the HTML content 
   from the Python script.
*/
.usage-list li .icon {
    font-size: 24px;
    line-height: 1;
    color: var(--primary-green);
    flex-shrink: 0;
    /* Prevents icon from shrinking */
    margin-top: 2px;
    /* Optical alignment with text */
}

.usage-list li div {
    flex: 1;
    /* Takes remaining space */
}

footer {
    background: var(--primary-green);
    color: #fff;
    padding: 60px 0;
    text-align: center;
    margin-top: 60px;
}
