/* Hoffmann Software – gemeinsamer Webrechner-Stil, Biorhythmus-Akzent.
 * Für Anlagerechner / Lotto-Experte können dieselben Basistokens genutzt werden;
 * die jeweiligen Diagrammfarben und Fachbedienungen bleiben produktspezifisch.
 */
:root {
  color-scheme: light;
  --hs-ink:#193047;
  --hs-text:#30495c;
  --hs-muted:#617588;
  --hs-line:#dbe4ec;
  --hs-blue:#216fb1;
  --hs-blue-hover:#185a92;
  --hs-blue-soft:#edf5fc;
  --hs-bg:#f4f7fa;
  --hs-paper:#ffffff;
  --hs-radius:13px;
  --hs-radius-sm:8px;
  --hs-shadow:0 3px 15px rgba(23,51,76,.045);
  --hs-max-width:1180px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
html,body{margin:0;min-height:100%;font:16px/1.5 system-ui,-apple-system,'Segoe UI',Arial,sans-serif;color:var(--hs-ink);background:var(--hs-bg)}
a{color:var(--hs-blue);text-underline-offset:3px}
button,input{font:inherit}
button{cursor:pointer}
.site{width:min(var(--hs-max-width),calc(100% - 40px));margin:0 auto}

/* Wiedererkennbare Markenleiste wie bei den anderen Webrechnern */
.header{display:grid;grid-template-columns:minmax(0,1fr) auto auto;align-items:center;column-gap:18px;row-gap:8px;min-height:99px;padding:20px 0}
.brand{display:flex;align-items:center;gap:12px;color:var(--hs-ink);text-decoration:none;min-width:0}
.brandmark{display:flex;align-items:center;justify-content:center;gap:1px;width:51px;height:51px;flex:0 0 51px;background:var(--hs-blue);color:#fff;border-radius:12px;font-size:27px;font-weight:800;letter-spacing:-2px}
.brandmark span{font-size:20px;align-self:flex-start;margin-top:6px;letter-spacing:0}
.brand-text{display:flex;flex-direction:column;line-height:1.22;gap:5px}
.brandname{font-weight:790;font-size:22px;letter-spacing:-.6px}
.subbrand{color:var(--hs-muted);font-size:13px;font-weight:530}
.product-nav{display:flex;align-items:center;justify-content:flex-end;gap:18px;flex-wrap:wrap}
.product-nav a{font-size:13px;font-weight:650;text-decoration:none;white-space:nowrap;color:var(--hs-text)}
.product-nav a:hover,.product-nav a:focus-visible{color:var(--hs-blue);text-decoration:underline}
.product-nav .original-link{color:var(--hs-blue)}

/* V5.2: gut sichtbarer Auswertungswähler direkt vor den Eingaben.
   Gleich breite Reiter, aktive Auswahl vollflächig blau; die Kopf- und Produktlinks
   bleiben bewusst unaufdringlich. */
.view-switch{background:#fff;border:1px solid #d3e0eb;border-radius:var(--hs-radius);box-shadow:var(--hs-shadow);padding:13px 14px 14px;margin:0 0 21px}
.view-switch-caption{color:var(--hs-muted);font-size:11px;font-weight:800;letter-spacing:1.15px;text-transform:uppercase;margin:0 0 9px 3px}
.tabs{display:grid;grid-template-columns:repeat(5,minmax(0,1fr));gap:8px}
.tab{display:flex;align-items:center;justify-content:center;text-align:center;min-height:47px;min-width:0;padding:10px 8px;border:1px solid #d8e3ec;border-radius:9px;background:#f5f8fb;color:var(--hs-text);text-decoration:none;font-size:14px;line-height:1.25;font-weight:700;transition:background .12s,border-color .12s,box-shadow .12s,color .12s}
.tab:hover{background:var(--hs-blue-soft);border-color:#96c3e4;color:var(--hs-blue-hover)}
.tab:focus-visible{outline:3px solid rgba(33,111,177,.35);outline-offset:2px}
.tab.active,.tab[aria-current="page"]{background:var(--hs-blue);border-color:var(--hs-blue);color:#fff;box-shadow:0 2px 7px rgba(33,111,177,.19)}
.tab.active:hover,.tab[aria-current="page"]:hover{background:var(--hs-blue-hover);border-color:var(--hs-blue-hover);color:#fff}
.headline{padding:31px 0 26px}
.eyebrow,.step{font-size:11px;letter-spacing:1.5px;font-weight:800;color:var(--hs-blue)}
.eyebrow{margin:0 0 9px}
.headline h1{font-size:clamp(25px,3.1vw,36px);letter-spacing:-.8px;line-height:1.2;margin:0 0 9px}
.intro{max-width:850px;margin:0;color:var(--hs-muted);line-height:1.55}
.section-heading{margin:27px 0 12px}
.section-heading h2{font-size:21px;margin:4px 0 0;letter-spacing:-.4px}

/* Formulare, Resultate, Erklärungen */
.control,.chartpanel,.note,.info{background:var(--hs-paper);border:1px solid var(--hs-line);border-radius:var(--hs-radius);box-shadow:var(--hs-shadow)}
.control{padding:24px}
.controlgrid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:17px}
.control label{display:flex;flex-direction:column;gap:8px;font-weight:650;font-size:13px;color:var(--hs-text)}
input{width:100%;min-width:0;min-height:45px;padding:9px 12px;border:1px solid #c7d5e0;border-radius:var(--hs-radius-sm);background:#fff;color:var(--hs-ink);font-size:15px}
input:focus-visible{outline:3px solid rgba(33,111,177,.18);border-color:var(--hs-blue)}
.controlsfooter{display:flex;align-items:center;gap:10px 16px;flex-wrap:wrap;margin-top:20px}
.buttonrow{display:flex;flex-wrap:wrap;gap:8px}
button{border-radius:var(--hs-radius-sm);padding:11px 16px;min-height:44px;font-size:14px;font-weight:700;border:1px solid transparent;transition:background .12s,border-color .12s}
button:focus-visible{outline:3px solid rgba(33,111,177,.23);outline-offset:2px}
button.primary{background:var(--hs-blue);border-color:var(--hs-blue);color:#fff}
button.primary:hover{background:var(--hs-blue-hover)}
button.subtle{background:#fff;border-color:#cbd9e5;color:var(--hs-text)}
button.subtle:hover{background:var(--hs-blue-soft);border-color:#9cbbd6;color:var(--hs-blue-hover)}
.status{padding:12px 16px;background:var(--hs-blue-soft);border:1px solid #c3dbf0;border-radius:var(--hs-radius-sm);color:var(--hs-blue-hover)}
.summary-strip{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;margin-top:19px}
.summary-strip>div{background:#e9f3fb;border:1px solid #d5e8f8;padding:17px 19px;border-radius:10px;display:flex;flex-direction:column;gap:3px}
.summary-strip strong{font-size:21px;line-height:1.3;font-variant-numeric:tabular-nums}
.subtle-label,.summary-strip small{font-size:12px;color:var(--hs-muted)}

.chartpanel{padding:23px 24px}
.charttop{display:flex;justify-content:space-between;align-items:flex-start;gap:16px}
.charttop h2{font-size:19px;margin:0 0 5px}
.charttop p{font-size:13px;color:var(--hs-muted);margin:0}
.chartwrap{height:440px;position:relative;margin:18px 0 8px}
.chartwrap canvas{display:block;width:100%!important;height:100%!important}
.legend{display:flex;flex-wrap:wrap;gap:10px 19px;padding:12px 0 3px}
.legend label{display:flex;gap:8px;align-items:center;font-size:13px;color:var(--hs-text);cursor:pointer}
.legend input{width:16px;min-height:16px;height:16px;margin:0;accent-color:var(--hs-blue)}
.legend .linekey{display:inline-block;width:23px;height:4px;border-radius:4px}
.cyclelegend{display:flex;flex-wrap:wrap;gap:8px 19px;border-top:1px solid var(--hs-line);margin-top:14px;padding-top:14px;color:var(--hs-muted);font-size:13px}
.cyclelegend span{display:inline-flex;align-items:center;gap:7px}
.cyclekey{width:12px;height:12px;border-radius:3px;display:inline-block}
.red{background:#e64b57}.green{background:#5dbd8c}.blue{background:#48a1dd}
.below{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:17px;margin:0 0 30px}
.note{padding:23px 25px}
.note h3{margin:0 0 10px;font-size:17px}
.note p{color:var(--hs-text);font-size:14px;line-height:1.65;margin:8px 0}
.secondary-note{background:#fbfcfe}
.info{padding:26px;line-height:1.7;margin-bottom:30px}
.info h2{margin-top:0}

/* Gemeinsamer, zurückhaltender Footer */
footer{border-top:1px solid var(--hs-line);padding:21px 0 30px;color:var(--hs-muted)}
.footer-main{display:flex;justify-content:space-between;gap:20px;font-size:13px}
.footer-main strong{color:var(--hs-ink);font-size:14px}
.footer-links{display:flex;gap:12px 20px;flex-wrap:wrap;align-items:center;justify-content:flex-end}
.footer-links a{color:var(--hs-text);text-decoration:none}
.footer-links a:hover{text-decoration:underline}
.footer-small{padding-top:20px;font-size:12px}

@media (max-width:1000px){
  .header{grid-template-columns:minmax(0,1fr) auto;grid-template-areas:"brand language" "nav nav";column-gap:12px;row-gap:10px;align-items:center}
  .header .brand{grid-area:brand}
  .header .product-nav{grid-area:nav;justify-content:flex-start}
  .header .language-strip{grid-area:language;justify-self:end}
}
@media (max-width:940px){.controlgrid{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media (max-width:610px){
  .site{width:calc(100% - 24px)}
  .header{padding:17px 0;gap:12px;min-height:auto}
  .brandmark{width:44px;height:44px;flex-basis:44px;font-size:24px}
  .brandmark span{font-size:16px}
  .brandname{font-size:19px}
  .product-nav{gap:8px 15px}
  .product-nav a{font-size:12px}
  .view-switch{padding:11px;margin-bottom:18px}
  .tabs{grid-template-columns:repeat(3,minmax(0,1fr));gap:7px}
  .tab{padding:10px 6px;min-height:43px;font-size:13px}
  .headline{padding:24px 0 13px}
  .section-heading{margin-top:24px}
  .section-heading h2{font-size:20px}
  .control,.chartpanel{padding:17px}
  .controlgrid{gap:13px}
  .controlsfooter{align-items:stretch}
  .controlsfooter .primary{flex:0 0 100%}
  .charttop{flex-direction:column}
  .chartwrap{height:330px}
  .summary-strip,.below{grid-template-columns:1fr}
  .footer-main{flex-direction:column}
  .footer-links{justify-content:flex-start}
}
@media (max-width:370px){.controlgrid{grid-template-columns:1fr}.tabs{grid-template-columns:repeat(2,minmax(0,1fr))}.tab{padding:10px 6px}}
/* Version 3: tatsächliches Hoffmann-Software-Logo statt erfundenem Signet. */
.brand-logo{display:block;flex:0 0 auto;width:149px;height:56px;object-fit:contain;background:transparent}
.brand{gap:17px}
.language-strip{display:flex;justify-content:flex-end;align-items:center;gap:8px;padding:0;white-space:nowrap}
.language-strip select{width:auto;max-width:220px;min-height:37px;padding:5px 13px;border:1px solid var(--hs-line);border-radius:8px;background:#fff;color:var(--hs-text);font:14px system-ui,sans-serif}
.ad-container{margin:21px 0 28px;padding:9px 8px 15px;background:#fff;border:1px solid var(--hs-line);border-radius:10px;min-height:100px;text-align:center}
.ad-label{display:block;color:#8795a1;text-transform:uppercase;font-size:10px;letter-spacing:1.2px;margin:0 0 9px}
@media(max-width:610px){
  .brand-logo{width:108px;height:41px}
  .brand{gap:9px}
  .brand-text{display:none}
  .language-strip{justify-content:flex-end;padding:0}
  .language-strip select{max-width:142px;font-size:13px;padding:5px 8px}
}


/* Der reine Diagrammbericht bleibt auf dem Bildschirm unsichtbar. */
.print-only{display:none!important}
.legend label.is-hidden{opacity:.44}

/* Druck-/PDF-Ansicht: genau ein Diagramm mit Daten und Erklärungen.
   Landschaft A4 bewahrt die Lesbarkeit längerer Datumsachsen. */
@page{size:A4 landscape;margin:7mm 11mm}
@media print{
  :root{color-scheme:light}
  html,body{margin:0!important;padding:0!important;background:#fff!important;color:#172d40!important;font:10pt/1.38 Arial,Helvetica,sans-serif!important;-webkit-print-color-adjust:exact;print-color-adjust:exact}
  .site{width:100%!important;max-width:none!important;margin:0!important}
  .header,.language-strip,.view-switch,.tabs,.headline,.control,.summary-strip,.status,
  .section-heading,.ad-container,footer,.footer-main,.footer-small,
  #save,#print,.charttop .buttonrow{display:none!important}
  .print-only{display:block!important}
  .print-report-header{display:block!important;margin:0 0 4mm;padding:0 0 3.5mm;border-bottom:1px solid #bed0de}
  .print-report-brand{display:flex!important;align-items:center;justify-content:flex-start;gap:5mm;min-height:14mm}
  .print-report-brand img{display:block;width:30mm;height:auto;max-height:13mm;object-fit:contain}
  .print-report-brand div{display:flex;flex-direction:column;gap:1mm}
  .print-report-brand strong{font-size:12pt;line-height:1.1;color:#193047}
  .print-report-brand span{font-size:8pt;color:#5c7183}
  .print-report-header h1{font-size:17pt;line-height:1.22;margin:4mm 0 1mm;letter-spacing:0;color:#193047}
  .print-report-header p{font-size:9pt;color:#526676;margin:0}
  .print-report-meta{display:grid!important;grid-template-columns:repeat(4,minmax(0,1fr));gap:2.6mm 4mm;padding:2.4mm 0 3mm;margin:0 0 3.5mm;border-bottom:1px solid #d8e2eb}
  .print-report-meta div{display:flex;flex-direction:column;min-width:0}
  .print-report-meta span{font-size:8pt;color:#5c7183;line-height:1.25}
  .print-report-meta strong{font-size:10pt;line-height:1.4;color:#162c3e;font-weight:bold;font-variant-numeric:tabular-nums}
  .chartpanel,.note,.info{box-shadow:none!important;border:0!important;border-radius:0!important;padding:0!important;margin:0!important;background:white!important}
  .chartpanel{break-inside:avoid;page-break-inside:avoid}
  .charttop{display:block!important;margin:0 0 2mm}
  .charttop h2{font-size:11pt;margin:0;font-weight:bold}
  .charttop p{display:none!important}
  .chartwrap{height:75mm!important;margin:0!important;display:block!important;overflow:hidden}
  .chartwrap canvas{display:none!important}
  .print-chart-image{display:block!important;width:100%!important;height:100%!important;object-fit:contain!important;object-position:center}
  .legend{gap:1.5mm 5mm!important;padding:2mm 0 0!important;display:flex!important;flex-wrap:wrap}
  .legend label{font-size:8.5pt!important;white-space:nowrap;gap:2mm;cursor:default}
  .legend label.is-hidden{display:none!important}
  .legend input{display:none!important}
  .legend .linekey{width:7mm;height:1.1mm}
  .cyclelegend{display:flex!important;gap:2mm 6mm!important;border-top:0!important;margin:1mm 0 0!important;padding:0!important;font-size:8.5pt!important}
  .cyclekey{width:3mm;height:3mm}
  .below{display:grid!important;grid-template-columns:1fr 1fr!important;gap:7mm!important;margin:4mm 0 0!important;padding:3mm 0 0!important;border-top:1px solid #d8e2eb}
  .note{break-inside:avoid;page-break-inside:avoid}
  .note h3{font-size:10pt;margin:0 0 1.5mm}
  .note p{font-size:8.7pt;line-height:1.36;margin:0 0 1.2mm!important;color:#30495c!important}
  a{color:inherit;text-decoration:none}
}

/* V5.1: schmaler, freiwilliger Opt-in statt großer Speicherkachel. */
.remember-inline{position:relative;display:flex;flex-wrap:wrap;align-items:center;gap:5px 12px;margin:8px 0 12px;padding:4px 2px;color:var(--hs-text);font-size:13px;line-height:1.4}
.remember-inline .memory-consent{display:inline-flex;align-items:center;gap:8px;font-size:13px;cursor:pointer;min-width:0}
.remember-inline .memory-consent input{flex:0 0 17px;width:17px;height:17px;min-width:17px;min-height:17px;margin:0;padding:0;accent-color:var(--hs-blue);cursor:pointer}
.memory-info{display:inline-block;flex:0 0 auto}
.memory-info summary{display:inline-flex;align-items:center;gap:4px;cursor:pointer;color:var(--hs-blue);font-size:12px;font-weight:600;list-style:none;padding:3px 4px;border-radius:5px;user-select:none}
.memory-info summary::-webkit-details-marker{display:none}
.memory-info summary:hover{text-decoration:underline}
.memory-info summary:focus-visible{outline:2px solid var(--hs-blue);outline-offset:2px}
.memory-info-icon{font-size:17px;line-height:1}
.memory-popout{position:absolute;z-index:20;right:0;top:calc(100% + 5px);width:min(465px,calc(100vw - 32px));max-height:min(62vh,470px);overflow:auto;padding:16px 18px;background:#fff;border:1px solid #cbd9e5;border-radius:10px;box-shadow:0 12px 26px rgba(18,43,65,.17);color:var(--hs-text);font-size:13px}
.memory-popout strong{display:block;font-size:14px;margin-bottom:7px;color:var(--hs-ink)}
.memory-popout p{line-height:1.55;margin:0 0 9px}
.memory-popout button.memory-delete{min-height:33px;padding:6px 12px;margin-top:3px;font-size:12px}
.memory-popout button[hidden]{display:none!important}
#memory-status{font-size:12px;color:var(--hs-muted);min-height:1px}
#memory-status:empty{display:none}
@media(max-width:610px){.remember-inline{padding:6px 2px;gap:4px 9px}.remember-inline .memory-consent{font-size:12.5px}.memory-popout{right:0;max-height:65vh}}
@media print{.remember-inline{display:none!important}}

/* V5.3: Sprache in der ersten Kopfzeile rechts statt eigener Leerzeile. */
@media(max-width:380px){.language-strip{gap:5px}.language-strip select{max-width:128px}.header{column-gap:8px}}

/* Nach einer Berechnung direkt zum Diagramm – kleiner Abstand zum Fensterrand. */
#diagramm{scroll-margin-top:14px}

/* V5.6: installierbare PWA und suchmaschinenlesbare Erläuterungen. */
.product-nav button.install-app{min-height:34px;font-size:12px;padding:6px 11px;border:1px solid #bfd1e1;border-radius:8px;background:#edf5fc;color:#185a92;font-weight:750;white-space:nowrap}
.product-nav button.install-app:hover{background:#dceefa}
.product-nav button.install-app[hidden]{display:none!important}
.seo-explainer{margin:22px 0 30px;padding:20px 24px;background:#fff;border:1px solid var(--hs-line);border-radius:var(--hs-radius);color:var(--hs-text)}
.seo-explainer h2{font-size:19px;margin:0 0 10px;color:var(--hs-ink)}
.seo-explainer p{margin:8px 0;line-height:1.62}
.seo-site-nav{display:flex;flex-wrap:wrap;gap:8px 17px;margin-top:14px;font-size:12px}
.seo-site-nav a{color:var(--hs-muted)}
.seo-site-nav a[aria-current="page"]{font-weight:750;color:var(--hs-blue)}
.pwa-dialog{border:1px solid var(--hs-line);border-radius:15px;box-shadow:0 16px 55px #132a4050;max-width:min(93vw,480px);padding:23px 26px;color:var(--hs-ink)}
.pwa-dialog::backdrop{background:#19304780}
.pwa-dialog h2{font-size:21px;margin:4px 0 14px;padding-right:22px}
.pwa-dialog p{line-height:1.6}
.pwa-dialog .pwa-close{float:right;font-size:25px;line-height:1;padding:0;min-height:30px;min-width:30px;background:transparent;border:0}
@media(max-width:610px){.seo-explainer{padding:17px}.product-nav button.install-app{font-size:12px}}
@media print{.seo-explainer,.seo-site-nav,.pwa-dialog{display:none!important}}
