/*
 * kogemand.css – Standarddesign til kogemanden-henrik.dk
 * Formål: Neutral og læsevenlig stil uden sæsontemaer
 * Udviklet af: ChatGPT & Henrik Larsen
 * Dato: Oktober 2025
 */

/* ========== BASISLAYOUT ========== */
body {
  background-color: #fefefe;
  color: #1c1c1c;
  font-family: 'Segoe UI', sans-serif;
  font-size: 18px;
  line-height: 1.6;
  padding: 10px;
}

/* ========== OVERSKRIFTER ========== */
h1, h2, h3, h4 {
  color: #2b2b2b;
  font-weight: 700;
  margin-top: 1.2em;
  margin-bottom: 0.4em;
}

/* ========== BRØDTEKST ========== */
p {
  margin-bottom: 1em;
}

/* ========== BILLEDER ========== */
img {
  display: block;
  margin: 20px auto;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
}

/* ========== CITATER / KASSER ========== */
.citat {
  background-color: #f8f8f8;
  border-left: 5px solid #888;
  padding: 12px 20px;
  margin: 20px 0;
  font-style: italic;
  border-radius: 6px;
}

/* ========== LINKS ========== */
a {
  color: #0056a3;
  text-decoration: underline dotted;
  transition: color 0.2s ease-in-out;
}

a:hover {
  color: #0078d7;
}

/* ========== KNAPPER ========== */
.knap-standard {
  background: linear-gradient(to right, #4b79a1, #283e51);
  border: none;
  color: white;
  padding: 10px 18px;
  border-radius: 6px;
  font-weight: bold;
  cursor: pointer;
  box-shadow: 0 4px 10px rgba(0,0,0,0.1);
  transition: background 0.3s ease;
}

.knap-standard:hover {
  background: linear-gradient(to right, #283e51, #4b79a1);
}

/* ========== FODNOTER / EKSTRA ========== */
.note {
  font-size: 0.9em;
  color: #555;
  border-top: 1px dashed #ccc;
  margin-top: 30px;
  padding-top: 10px;
}

/* ================================
   NEWSLETTER ARCHIVE
================================ */
.newsletter-archive-wrapper {
    max-width: 950px;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 14px;
    padding: 25px;
    box-shadow: 0 2px 18px rgba(0,0,0,0.08);
}

.newsletter-archive-iframe {
    width: 100% !important;
    height: 1800px !important;
    border: none !important;
    overflow: hidden;
}

@media (max-width: 768px) {
    .newsletter-archive-iframe {
        height: 2300px !important;
    }
}

/* ================================
   ACYMAILING – LISTE VISNING
================================ */
.acym_archive_listing,
.acym_archive_listing * {
    font-size: 16px !important;
    line-height: 1.7 !important;
    font-family: 'Inter', 'Arial', sans-serif !important;
    color: #222 !important;
}

.acym__archive__listing__item {
    padding: 12px 0 !important;
    border-bottom: 1px solid #eee !important;
}

.acym__archive__listing__date {
    color: #666 !important;
    font-size: 14px !important;
}

.acym__archive__listing__subject {
    font-weight: 600 !important;
    color: #202020 !important;
}

/* ================================
   FOOTER PRIVACY LINKS
================================ */
.footer-privacy {
    text-align: center;
    padding: 15px 0;
}

.footer-privacy a {
    display: inline-block;
    margin: 0 10px;
    padding: 6px 14px;
    border-radius: 6px;
    background: rgba(255,255,255,0.08);
    color: #ffffff !important;
    font-size: 16px;
    text-decoration: none !important;
    transition: all 0.25s ease;
    border: 1px solid rgba(255,255,255,0.2);
}

.footer-privacy a:hover {
    background: rgba(255,255,255,0.2);
    transform: translateY(-2px);
    border-color: #ffffff;
}

.footer-privacy a i {
    margin-right: 6px;
    font-size: 18px;
}

/* ================================
   ASTROID FOOTER ACCORDION
================================ */
.astroid-accordion {
    background-color: #2c3e50 !important;
    border: 1px solid #3c5065 !important;
    border-radius: 10px !important;
    margin: 0 auto 20px auto !important;
}

.astroid-accordion .card-header {
    background: transparent !important;
    color: #ffffff !important;
    padding: 12px 20px !important;
    border-bottom: 1px solid #3c5065 !important;
}

.astroid-accordion .card-body {
    background: #2c3e50 !important;
    color: #ffffff !important;
    padding: 15px 20px !important;
}

.astroid-accordion a {
    color: #73c2ff !important;
    text-decoration: underline !important;
}

/* ================================
   POLITIKKER / PRIVATLIV
================================ */
.policy-wrapper {
    background: #ffffff;
    padding: 2rem;
    border-radius: 16px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.08);
    max-width: 1100px;
    margin: 0 auto 3rem auto;
}

.policy-paper {
    background: #f7f5f0;
    padding: 40px 35px;
    border-radius: 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
    max-width: 980px;
    margin: 40px auto;
}

.policy-paper h1,
.policy-paper h2,
.policy-paper h3 {
    color: #333;
    font-weight: 700;
}

.policy-section {
    margin-bottom: 28px;
}

.policy-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
}

.policy-nav a {
    background: #fff;
    border: 2px solid #62b27f;
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 15px;
    color: #3b7b52;
    text-decoration: none;
}
.policy-nav a:hover {
    background: #62b27f;
    color: #fff;
}
/* =========================================================
   FIX: Næringsindhold (JoomRecipe)
   Problem:
   - Sitet kører dark-mode (color-scheme: dark)
   - Nutrition-blokken har lys baggrund
   - Teksten bliver derfor hvid på lys baggrund (usynlig)
   Løsning:
   - Tving mørk tekstfarve lokalt i #JRnutrition
   ========================================================= */

#JRnutrition {
  color: #111 !important;
}

#JRnutrition table,
#JRnutrition table td,
#JRnutrition table th,
#JRnutrition table span,
#JRnutrition p,
#JRnutrition strong {
  color: #111 !important;
  opacity: 1 !important;
}
/* =========================================================
   FIX: JoomRecipe Næringsindhold – table-striped (hver anden række usynlig)
   ========================================================= */

#JRnutrition table {
  /* Basis (alle rækker) */
  --bs-table-color: #111;
  --bs-table-bg: transparent;

  /* Striber (hver anden række) */
  --bs-table-striped-color: #111;
  --bs-table-striped-bg: rgba(0,0,0,.03);

  /* Hover (hvis det bruges) */
  --bs-table-hover-color: #111;
  --bs-table-hover-bg: rgba(0,0,0,.06);
}

/* Sikkerhed: tving tekstfarve i celler (hvis noget overskriver variabler) */
#JRnutrition table td,
#JRnutrition table th,
#JRnutrition table td * ,
#JRnutrition table th * {
  color: #111 !important;
}
/* FIX: JoomRecipe ingredienser bliver hvide ved scroll (Bootstrap table bug) */
.jbIngredients table td,
.jbIngredients table td span,
.jbIngredients table td span.ingredient{
  color: #111 !important;
  background: transparent !important;
  box-shadow: none !important;
}
.jbIngredients table{
  --bs-table-color: #111;
  --bs-table-color-state: #111;
  --bs-table-bg: transparent;
  --bs-table-bg-state: transparent;
  --bs-table-striped-color: #111;
}
/* Fix: JoomRecipe ingredients disappearing on scroll */
.jbIngredients table,
.jbIngredients td,
.jbIngredients span,
.jbIngredients tr {
  color: #000 !important;
  background-color: transparent !important;
  box-shadow: none !important;
}

.jbIngredients {
  position: relative;
  z-index: 1;
}
/* FIX: JoomRecipe content forsvinder ved scroll */
.recipe-more-info,
.recipe-more-info .card,
.recipe-more-info .card-body,
#RecipeListing,
#jb_template,
.astroid-component,
.main.astroid-component-area {
  overflow: visible !important;
  max-height: none !important;
  height: auto !important;
}
/* Force readable text for light themes */
.com_joomrecipe {
  --bs-body-color: #212529;
  --bs-table-color: #212529;
}

.com_joomrecipe span.ingredient,
.com_joomrecipe table,
.com_joomrecipe table td,
.com_joomrecipe table th {
  color: #212529 !important;
}

/* =========================================================
   NS Pro – Kogemanden styling (REN / 1 sandhed)
   Formål:
   - Form som “kort”
   - Inputfelter med svag grøn baggrund (#EAF6E5)
   - Tydelig fokus
   - Pæn checkbox-liste
   - Knap: hvis kh-nspro-btn er sat i modulet, bruges den.
     Ellers styles btn btn-primary som fallback.
   ========================================================= */

/* Form-wrapper som kort */
.modnspro form {
  padding: 18px !important;
  background: #ffffff !important;
  border: 1px solid #d7dddd !important;
  border-radius: 14px !important;
  box-shadow: 0 10px 24px rgba(0,0,0,0.06) !important;
}

/* Luft mellem felter */
.modnspro .nspro_field {
  margin-bottom: 14px !important;
}

/* ATOMBOMBE – kun inde i NS Pro-formen */
.modnspro form .form-control,
.modnspro form input[type="text"],
.modnspro form input[type="email"],
.modnspro form input[type="tel"],
.modnspro form select,
.modnspro form textarea {
  width: 100% !important;
  padding: 14px 14px !important;
  border: 2px solid #d2e7cc !important;
  border-radius: 10px !important;
  background-color: #EAF6E5 !important;
  color: #111111 !important;
  font-size: 15px !important;
  line-height: 22px !important;
  box-shadow: none !important;
}

/* Placeholder tydeligere */
.modnspro form .form-control::placeholder,
.modnspro form input::placeholder,
.modnspro form textarea::placeholder {
  color: #5f6f63 !important;
  opacity: 1 !important;
}

/* Fokus – elegant og tydelig */
.modnspro form .form-control:focus,
.modnspro form input:focus,
.modnspro form select:focus,
.modnspro form textarea:focus {
  outline: none !important;
  background-color: #ffffff !important;
  border-color: #2f6f6d !important;
  box-shadow: 0 0 0 4px rgba(47,111,109,0.15) !important;
}

/* Checkbox-sektion (mailing lists) lidt “samlet” */
.modnspro .mailing_lists_field,
.modnspro .nspro_field.mailing_lists_field {
  padding: 12px 12px !important;
  border: 1px solid #e6ecec !important;
  border-radius: 12px !important;
  background: #fbfcfc !important;
}

/* Links i formen (privatlivspolitik) */
.modnspro form a {
  color: #2f6f6d !important;
  text-decoration: underline !important;
}

/* Knap – hvis du har sat 'kh-nspro-btn' i modulet */
.modnspro .kh-nspro-btn {
  background: #111111 !important;
  border-color: #111111 !important;
  color: #ffffff !important;
  border-radius: 10px !important;
  padding: 12px 18px !important;
  font-size: 15px !important;
  font-weight: 700 !important;
}

.modnspro .kh-nspro-btn:hover {
  background: #2f6f6d !important;
  border-color: #2f6f6d !important;
}

/* Fallback: hvis knappen stadig kun er btn btn-primary */
.modnspro form .btn.btn-primary {
  background: #111111 !important;
  border-color: #111111 !important;
  color: #ffffff !important;
  border-radius: 10px !important;
  padding: 12px 18px !important;
  font-size: 15px !important;
  font-weight: 700 !important;
}

.modnspro form .btn.btn-primary:hover {
  background: #2f6f6d !important;
  border-color: #2f6f6d !important;
}
/* ================================
   FAKTABOKS – Artikler (Kogemanden)
================================ */

.kh-faktaboks {
  background: #f4f7f6;
  border: 1px solid #d9e3e1;
  border-left: 6px solid #2f6f6d;
  padding: 18px 22px;
  margin: 28px 0;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.05);
}

.kh-faktaboks h4 {
  margin-top: 0;
  margin-bottom: 10px;
  font-size: 18px;
  font-weight: 700;
  color: #2f6f6d;
}

.kh-faktaboks ul {
  margin: 0;
  padding-left: 18px;
}

.kh-faktaboks li {
  margin-bottom: 6px;
}

/* =========================================================
   KOGEMANDEN HENRIK – GREENFRUIT TABELSTANDARD
   Anvendelse:
   - Grøntsagernes Verden
   - Frugternes Verden
   - Viden om mad

   HTML: <table class="greenfruit">

   Fælles tabeldesign med skiftevis hvide og
   lysegrå rækker, som i rødkål og pak choi.
   ========================================================= */

table.greenfruit {
    width: 100%;
    max-width: 950px;
    border-collapse: collapse;
    text-align: left;
    color: #141414;
}

/* Tabeloverskrifter */
table.greenfruit thead th {
    background-color: #E5E5E5;
    color: #141414;
    padding: 12px 20px;
    text-align: left;
    font-weight: 700;
}

/* Almindelige tabelceller */
table.greenfruit tbody td {
    padding: 8px 20px;
    vertical-align: top;
    color: #141414;
}

/* Hvide rækker */
table.greenfruit tbody tr:nth-child(odd) > td {
    background-color: #FFFFFF;
}

/* Lysegrå rækker */
table.greenfruit tbody tr:nth-child(even) > td {
    background-color: #F2F2F2;
}

/* Bootstrap/Astroid: bevar cellernes baggrund */
table.greenfruit {
    --bs-table-bg: transparent;
    --bs-table-striped-bg: transparent;
    --bs-table-color: #141414;
}

/* Mobilvisning */
@media (max-width: 600px) {
    table.greenfruit thead th,
    table.greenfruit tbody td {
        padding: 8px 10px;
        font-size: 14px;
    }
}
