/*
Theme Name: samio4mars
Theme URI: https://samio.se
Author: Rikard Linde
Author URI: https://rikardlinde.se
Description: Tema för Samio – solpaneler, batterier och fri energi för svenska hushåll.
Version: 1.0.0
License: CC-BY-SA 4.0
License URI: https://creativecommons.org/licenses/by-sa/4.0/deed.sv
Text Domain: samio
*/


/* ════════════════════════════════════════
   1. RESET & GRUND
   ════════════════════════════════════════ */

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
               "Helvetica Neue", Arial, sans-serif;
  line-height: 1.5;
  color: #111827;
  background-color: #ffffff;
}

a {
  color: #224C80;
  text-decoration: underline;
}

a:hover {
  color: #224C80;
  text-decoration: none;
}

button {
  font-family: inherit;
  background: none;
  border: none;
  cursor: pointer;
}


/* ════════════════════════════════════════
   2. HJÄLPKLASSER
   ════════════════════════════════════════ */

.hidden {
  display: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.inline-icon {
  width: 1em;
  height: 1em;
  vertical-align: -0.125em;
  color: #6b7280;
}


/* ════════════════════════════════════════
   3. SIDLAYOUT
   ════════════════════════════════════════ */

.page-wrapper {
  min-height: 100vh;
  background-color: #ffffff;
  display: flex;
  flex-direction: column;
}

.main-content {
  max-width: 64rem;
  margin: 0 auto;
  padding: 3rem 1.5rem;
  flex-grow: 1;
  width: 100%;
}

/* Inre wrapper utan egen padding (förstasidan) */
.main-content-inner {
  max-width: 64rem;
  margin: 0 auto;
  padding: 0;
}


/* ════════════════════════════════════════
   4. HEADER
   ════════════════════════════════════════ */

.header {
  border-bottom: 1px solid #e5e7eb;
  background-color: #ffffff;
  position: sticky;
  top: 0;
  z-index: 10;
}

.header-container {
  max-width: 64rem;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* ── Logotyp & tagline ── */

.logo a img {
  width: 150px;
}

.logo a {
  color: inherit;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.logo a:hover {
  text-decoration: none;
}

.tagline {
  display: block;
  font-size: 0.75rem;
  font-weight: 800;
  font-style: normal;
  color: #6b7280;
  letter-spacing: 0.05em;
  margin-top: 0.125rem;
}

/* ── Navigeringslänkar (gemensamt) ── */

.nav-link {
  color: #111827;
  text-decoration: none;
  transition: color 0.2s;
}

.nav-link:hover {
  color: #374151;
}

.nav-arrow {
  display: inline-block;
  width: 0.4em;
  height: 0.4em;
  border-right: 1.5px solid #111827;
  border-bottom: 1.5px solid #111827;
  transform: rotate(45deg);
  margin-left: 1px;
  vertical-align: middle;
  margin-bottom: 3px;
}

/* ── Kontakt i header (desktop) ── */

.header-contact {
  display: none;
  font-style: normal;
  font-size: 0.8rem;
  color: #000;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.1rem;
  line-height: 1.3;
}

.header-contact a {
  color: #000;
	background: yellow;
  text-decoration: none;
}

.header-contact a:hover {
  color: #111827;
	text-decoration: underline;
}

@media (min-width: 768px) {
  .header-contact { display: flex; }
}

/* ════════════════════════════════════════
   4a. DESKTOP-NAVIGERING
   ════════════════════════════════════════ */

.nav-desktop {
  display: none;
  gap: 1.5rem;
  list-style: none;
  align-items: center;
}

.nav-desktop > li {
  position: relative;
}

/* Aktiv sida */
.nav-desktop > .current-menu-item > a,
.nav-desktop > .current-menu-ancestor > a,
.nav-desktop > .current_page_item > a,
.nav-desktop > .current_page_ancestor > a {
  font-weight: 600;
}

/* ── Desktop-undermenyer ── */

.submenu,
.sub-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: -0.75rem;
  padding-top: 0.5rem;
  list-style: none;
  z-index: 20;
}

/* Osynlig brygga mellan förälder och undermeny */
.submenu::before,
.sub-menu::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 0.5rem;
}

.menu-item-has-children:hover > .sub-menu,
.menu-item-has-children:focus-within > .sub-menu,
.has-submenu:hover .submenu,
.has-submenu:focus-within .submenu {
  display: block;
}

.submenu li,
.sub-menu li {
  background: #ffffff;
  border-left: 1px solid #e5e7eb;
  border-right: 1px solid #e5e7eb;
}

.submenu li:first-child,
.sub-menu li:first-child {
  border-top: 1px solid #e5e7eb;
  border-radius: 0.375rem 0.375rem 0 0;
}

.submenu li:last-child,
.sub-menu li:last-child {
  border-bottom: 1px solid #e5e7eb;
  border-radius: 0 0 0.375rem 0.375rem;
}

.submenu a,
.sub-menu a {
  display: block;
  padding: 0.5rem 1rem;
  white-space: nowrap;
  color: #111827;
  text-decoration: none;
  transition: background-color 0.15s;
}

.submenu a:hover,
.sub-menu a:hover {
  background-color: #f3f4f6;
}

.submenu .current-menu-item > a,
.submenu .current_page_item > a {
  font-weight: 600;
  background-color: #f3f4f6;
}


/* ════════════════════════════════════════
   4b. MOBIL-NAVIGERING
   Alltid utfälld (likt sverigesradio.se)
   ════════════════════════════════════════ */

.mobile-menu-btn {
  display: block;
  color: #111827;
}

.menu-icon,
.close-icon {
  width: 24px;
  height: 24px;
}

.nav-mobile {
  border-top: 1px solid #e5e7eb;
  background-color: #ffffff;
}

.nav-mobile-container {
  max-width: 64rem;
  margin: 0 auto;
  padding: 1.5rem 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 0;
  list-style: none;
}

.nav-mobile-container a {
  text-decoration: none;
}

/* Toppnivå */
.nav-mobile-container > li > a {
  display: block;
  padding: 0.75rem 0;
  font-size: 1.125rem;
  font-weight: 500;
  color: #111827;
  text-decoration: none;
  border-bottom: 1px solid #f3f4f6;
}

.nav-mobile-container > li:last-child > a {
  border-bottom: none;
}

/* Aktiv sida */
.nav-mobile-container > li.current-menu-item > a,
.nav-mobile-container > li.current-menu-ancestor > a,
.nav-mobile-container > li.current_page_item > a,
.nav-mobile-container > li.current_page_ancestor > a {
  font-weight: 700;
}

/* Förälder med undersidor */
.nav-mobile-container > li.menu-item-has-children {
  border-bottom: 1px solid #f3f4f6;
  padding-bottom: 0.5rem;
}

.nav-mobile-container > li.menu-item-has-children > a {
  border-bottom: none;
}

/* Undersidor */
.mobile-submenu-list {
  list-style: none;
  padding-left: 1rem;
  padding-top: 0;
  padding-bottom: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.mobile-submenu-list li a {
  display: block;
  padding: 0.5rem 0;
  font-size: 1rem;
  color: #374151;
  text-decoration: none;
  transition: color 0.2s;
}

.mobile-submenu-list li a:hover {
  color: #111827;
}

.mobile-submenu-list .current-menu-item > a,
.mobile-submenu-list .current_page_item > a {
  font-weight: 600;
  color: #111827;
}


/* ════════════════════════════════════════
   4c. SÖKFÄLT
   ════════════════════════════════════════ */

/* ── Desktop ── */

.header-search {
  display: none;
}

.header-search form {
  display: flex;
  align-items: center;
  border: 1px solid #e5e7eb;
  border-radius: 0.375rem;
  overflow: hidden;
  transition: border-color 0.2s;
}

.header-search form:focus-within {
  border-color: #9ca3af;
}

.header-search-input {
  border: none;
  outline: none;
  padding: 0.375rem 0.625rem;
  font-size: 0.875rem;
  width: 10rem;
  background: transparent;
  color: #111827;
  font-family: inherit;
}

.header-search-input::placeholder {
  color: #9ca3af;
}

.header-search-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.375rem 0.5rem;
  color: #6b7280;
  transition: color 0.2s;
}

.header-search-btn:hover {
  color: #111827;
}

/* ── Mobil ── */

.mobile-search {
  padding: 0.5rem 1.5rem 1rem;
}

.mobile-search form {
  display: flex;
  align-items: center;
  border: 1px solid #e5e7eb;
  border-radius: 0.375rem;
  overflow: hidden;
}

.mobile-search form:focus-within {
  border-color: #9ca3af;
}

.mobile-search-input {
  border: none;
  outline: none;
  padding: 0.625rem 0.75rem;
  font-size: 1rem;
  width: 100%;
  background: transparent;
  color: #111827;
  font-family: inherit;
}

.mobile-search-input::placeholder {
  color: #9ca3af;
}

.mobile-search-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.625rem 0.75rem;
  color: #6b7280;
  transition: color 0.2s;
}

.mobile-search-btn:hover {
  color: #111827;
}

/* ── Sökresultat ── */

.search-count {
  color: var(--color-text-light, #666);
  margin-block-end: 2rem;
}

.search-no-results {
  padding-block: 3rem;
  color: var(--color-text-light, #666);
}

.search-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-text-light, #666);
  margin-block-end: 0.25rem;
}


/* ════════════════════════════════════════
   5. BRÖDSMULOR
   Schema.org BreadcrumbList
   ════════════════════════════════════════ */

.breadcrumbs ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  font-size: 0.875rem;
  margin-bottom: 0.75rem;
}

.breadcrumbs li + li::before {
  content: "›";
  margin: 0 0.4em;
  color: #9ca3af;
}

.breadcrumbs a {
  color: #6b7280;
  text-decoration: none;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

.breadcrumbs [aria-current="page"] {
  color: #374151;
}


/* ════════════════════════════════════════
   6. HERO
   Sidrubriker och toppbilder
   ════════════════════════════════════════ */

.hero-section {
  margin-bottom: 3rem;
}

.hero-title {
  font-size: 3rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  color: #1f2937;
  line-height: 1.1;
  letter-spacing: -2px;
}

.hero-image-wrapper {
  margin-bottom: 4rem;
}

.hero-image {
  width: 100%;
  height: 16rem;
  object-fit: cover;
  border-radius: 0.5rem;
}


/* ════════════════════════════════════════
   7. KORT & LISTOR
   Återanvändbara komponenter
   ════════════════════════════════════════ */

/* ── Grundkort ── */

.card {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow: hidden;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card-flex {
  display: flex;
  flex-direction: column;
}

.card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.card-content-flex {
  flex: 1;
}

.card-footer {
  display: block;
  padding: 1rem 1.5rem;
  border-top: 1px solid #e5e7eb;
  background-color: #f9fafb;
  font-size: 0.875rem;
  font-weight: 500;
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
}

.card-footer:hover {
  background-color: #f3f4f6;
  text-decoration: none;
}

.footer-content {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.footer-content .arrow-icon {
  transition: transform 0.2s;
}

.card-footer:hover .footer-content .arrow-icon {
  transform: translateX(0.25rem);
}

/* Klickbar kortyta (bild + text) */
.card-link-wrapper {
  display: block;
  color: inherit;
  text-decoration: none;
  transition: background-color 0.2s;
}

.card-link-wrapper:hover {
  text-decoration: none;
  background-color: #f9fafb;
}

.card-top-image {
  width: 100%;
  height: 10rem;
  object-fit: cover;
  display: block;
}

/* ── Listobjekt med pil ── */

.list-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: #111827;
  transition: color 0.2s;
}

.list-item:hover {
  color: #374151;
}

.arrow-icon {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  transition: transform 0.2s;
}

.list-item:hover .arrow-icon {
  transform: translateX(0.25rem);
}

/* ── Sektionsrubriker med ikon ── */

.section {
  display: flex;
  flex-direction: column;
}

.section-header-link {
  margin-bottom: 1.5rem;
  display: inline-block;
  text-decoration: none;
}

.section-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: #1f2937;
  line-height: 1.1;
  letter-spacing: -1px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  transition: color 0.2s;
}

.section-header-link:hover .section-title {
  color: #374151;
}

.section-icon {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

/* ── Ikonfärger ── */

.icon-green,
.footer-green { color: #009246; }

.icon-blue,
.footer-blue { color: #0066CC; }

.icon-red,
.footer-red { color: #CE2B37; }

/* ── Innehållsrutnät ── */

.content-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 2.5rem;
  margin-bottom: 2.5rem;
}


/* ════════════════════════════════════════
   8. FÖRSTASIDA
   ════════════════════════════════════════ */

.front-section {
  margin-bottom: 2.5rem;
}

/* ── Hero-banner (mörk, standard) ── */

.hero-banner {
  position: relative;
  overflow: hidden;
  border-radius: 0.5rem;
  background-color: #1f2937;
}

.hero-banner img {
  width: 100%;
  aspect-ratio: 21 / 9;
  object-fit: cover;
  display: block;
}

.hero-banner-content {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2.5rem;
}

.hero-banner-title {
  font-size: 2.5rem;
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
  letter-spacing: -1.5px;
  margin-bottom: 0.5rem;
}

.hero-banner-subtitle {
  font-size: 1.125rem;
  line-height: 1.1;
  letter-spacing: -0.5px;
  color: rgba(255, 255, 255, 0.85);
  max-width: 28rem;
}

.hero-banner-link {
  text-decoration: none;
  display: block;
}

.hero-banner-link:hover {
  text-decoration: none;
}

.hero-banner-link:hover .hero-banner {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ── Hero-banner (ljus) ── */

.hero-banner-light {
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
}

.hero-banner-light img {
  opacity: 1;
  width: 100%;
  height: auto;
  aspect-ratio: 5 / 2;
  object-fit: cover;
}

.hero-banner-light .hero-banner-content {
  position: relative;
  inset: auto;
  padding: 2rem 2.5rem 2.5rem;
}

.hero-banner-light .hero-banner-title {
  color: #1f2937;
}

.hero-banner-light .hero-banner-subtitle {
  color: #4b5563;
}

/* ── Hero-banner (poster — röd text, som affisch) ── */

.hero-banner-poster {
  background-color: #ffffff;
}

.hero-banner-poster img {
  opacity: 0.75;
}

.hero-banner-poster .hero-banner-content {
  justify-content: space-between;
  padding: 2rem 2.5rem;
}

.hero-poster-top,
.hero-poster-bottom {
  color: #ff0000;
  font-family: "Impact", "Arial Narrow", sans-serif;
  font-style: italic;
  font-weight: 700;
  text-align: right;
  font-size: 3.5rem;
  font-stretch: condensed;
}

.hero-poster-bottom {
  max-width: none;
}

.hero-poster-top {
  margin-top: 30px;
}

.hero-poster-bottom {
  position: relative;
  top: -60px;
}

/* ── Grid-layouter ── */

.front-grid-3 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.front-grid-2 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

/* ── Pressruta ── */

.press-card {
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-decoration: none;
  transition: box-shadow 0.2s;
}

.press-card:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
              0 2px 4px -1px rgba(0, 0, 0, 0.06);
  text-decoration: none;
}

.press-source {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin-bottom: 0.5rem;
}

.press-quote {
  font-size: 1.3rem;
	font-weight:600;
  font-style: italic;
  color: #1f2937;
  line-height: 1.5;
}

.press-quote:before {
  content: '"';
}

.press-quote:after {
  content: '"';
}

/* ── Kontakt + följ ── */

.contact-follow-card {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.contact-block {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex-grow: 1;
}

.contact-block p {
  font-size: 0.95rem;
  color: #111827;
}

.contact-label,
.follow-label {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin-bottom: 0.25rem;
}

.follow-block {
  padding: 1rem 1.5rem;
  border-top: 1px solid #e5e7eb;
  background-color: #f9fafb;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.follow-links {
  display: flex;
  gap: 0.75rem;
  font-size: 0.95rem;
}

#hor-av-dig {
  margin-top: 24px;
}

/* ── Batterirutor ── */

.battery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
}

.battery-card {
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow: hidden;
  text-decoration: none;
  transition: box-shadow 0.2s;
  display: flex;
  flex-direction: column;
}

.battery-card:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
              0 2px 4px -1px rgba(0, 0, 0, 0.06);
  text-decoration: none;
}

.battery-card img {
  width: 100%;
  height: 8rem;
  object-fit: cover;
  display: block;
}

.battery-card-text {
  padding: 0.75rem;
}

.battery-card-title {
  font-size: 0.85rem;
  font-weight: 500;
  color: #111827;
}

/* ── Statistikkort ── */

.stats-card {
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  transition: box-shadow 0.2s;
}

.stats-card:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
              0 2px 4px -1px rgba(0, 0, 0, 0.06);
  text-decoration: none;
}

.stats-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
  margin-bottom: 1rem;
}

.stats-chart-placeholder {
  flex: 1;
  min-height: 8rem;
  display: flex;
  align-items: flex-end;
  gap: 0.25rem;
  padding-top: 1rem;
}

.stats-bar {
  flex: 1;
  background-color: #d1d5db;
  border-radius: 0.125rem 0.125rem 0 0;
  transition: background-color 0.2s;
}

.stats-card:hover .stats-bar {
  background-color: #9ca3af;
}

.stats-source {
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 0.75rem;
}


/* ════════════════════════════════════════
   9. GUIDER & KURSER
   ════════════════════════════════════════ */

.guides-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  flex: 1;
}

.guide-card {
  background-color: #f9fafb;
  border-radius: 0.5rem;
  padding: 1.5rem;
  text-decoration: none;
  transition: box-shadow 0.2s;
}

.guide-card:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
              0 2px 4px -1px rgba(0, 0, 0, 0.06);
  text-decoration: none;
}

.guide-card-image {
  background-color: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  overflow: hidden;
  text-decoration: none;
  transition: box-shadow 0.2s;
}

.guide-card-image:hover {
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1),
              0 2px 4px -1px rgba(0, 0, 0, 0.06);
  text-decoration: none;
}

.guide-title {
  font-size: 0.875rem;
  font-weight: 500;
  font-style: italic;
  color: #111827;
}

.guide-image {
  width: 100%;
  height: 10rem;
  object-fit: cover;
  display: block;
}

.guide-image-text {
  padding: 1rem;
}

.chart-wrapper {
  margin-bottom: 1rem;
}

.chart {
  width: 100%;
  height: auto;
  display: block;
}

/* Foton */
.photos-content {
  padding: 1.5rem;
  flex: 1;
}

.photos-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

.photo {
  width: 100%;
  height: 6rem;
  object-fit: cover;
  border-radius: 0.25rem;
  display: block;
}


/* ════════════════════════════════════════
   10. PRODUKTER
   ════════════════════════════════════════ */

.guidance-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.guidance-grid .guide-card-image {
  display: flex;
  flex-direction: column;
}

.guidance-grid .guide-image {
  height: 10rem;
}


/* ════════════════════════════════════════
   11. BLOGG
   Enskilda inlägg och arkiv
   ════════════════════════════════════════ */

/* ── Enskilt inlägg ── */

.blog-post {
  max-width: 40rem;
}

.blog-title {
  font-size: 2.25rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  color: #1f2937;
  line-height: 1.1;
  letter-spacing: -2px;
}

.blog-image-container {
  margin-bottom: 3rem;
}

.blog-image {
  width: 100%;
  height: 16rem;
  object-fit: cover;
  border-radius: 0.5rem;
  display: block;
}

.blog-section {
  margin-top: 2.5rem;
}

.blog-heading {
  font-size: 1.5rem;
  font-weight: 600;
  color: #1f2937;
  line-height: 1.2;
  letter-spacing: -0.025em;
  margin-bottom: 1rem;
}

.blog-subheading {
  font-size: 1.125rem;
  font-weight: 600;
  color: #1f2937;
  line-height: 1.3;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.blog-ingress {
  font-size: 1.125rem;
  line-height: 1.6;
  color: #374151;
  margin-bottom: 2rem;
}

.blog-text {
  margin-bottom: 1.5rem;
  color: #111827;
  line-height: 1.625;
  font-size: 1rem;
}

.blog-aside {
  background-color: #f9fafb;
  border-left: 3px solid #e5e7eb;
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  border-radius: 0 0.375rem 0.375rem 0;
}

.blog-aside .blog-text {
  margin-bottom: 0;
}

.blog-list {
  margin-bottom: 2rem;
  padding-left: 1.25rem;
}

.blog-list-item {
  color: #111827;
  line-height: 1.625;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

/* ── Arkiv ── */

.blog-archive {
  max-width: 40rem;
}

.blog-archive-list {
  display: flex;
  flex-direction: column;
}

.blog-archive-item {
  border-bottom: 1px solid #e5e7eb;
  padding: 2rem 0;
}

.blog-archive-item:first-child {
  padding-top: 0;
}

.blog-archive-item:last-child {
  border-bottom: none;
}

.blog-archive-link {
  display: block;
  text-decoration: none;
}

.blog-archive-link:hover {
  text-decoration: none;
}

.blog-archive-link:hover .blog-archive-title {
  color: #374151;
}

.blog-archive-figure {
  margin-bottom: 1rem;
}

.blog-archive-image {
  width: 100%;
  height: 12rem;
  object-fit: cover;
  border-radius: 0.5rem;
  display: block;
}

.blog-archive-time {
  display: block;
  font-size: 0.875rem;
  color: #6b7280;
  margin-bottom: 0.375rem;
}

.blog-archive-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: #1f2937;
  line-height: 1.2;
  letter-spacing: -1px;
  margin-bottom: 0.5rem;
  transition: color 0.2s;
}

.blog-archive-excerpt {
  color: #4b5563;
  line-height: 1.625;
  font-size: 1rem;
}

figure.wp-block-image:nth-child(16) > figcaption:nth-child(2) > a:nth-child(1) {
  color: #6b7280;
}

@media (min-width: 768px) {
  .contact-box {
    position: sticky;
    top: 6rem;
  }
}


/* ════════════════════════════════════════
   12. WORDPRESS-INNEHÅLL
   Klasser som WordPress genererar via
   the_content() i entry-content
   ════════════════════════════════════════ */

.entry-content p {
  margin-bottom: 1.5rem;
  color: #111827;
  line-height: 1.625;
  font-size: 1rem;
}

.entry-content h2 {
  font-size: 1.5rem;
  font-weight: 800;
  color: #1f2937;
  line-height: 1.4;
  letter-spacing: -1px;
  margin-top: 2.5rem;
  margin-bottom: 1rem;
}

.entry-content h3 {
  font-size: 1.125rem;
  font-weight: 800;
  color: #1f2937;
  line-height: 1.3;
  letter-spacing: -1px;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.entry-content ul,
.entry-content ol {
  margin-bottom: 2rem;
  padding-left: 1.25rem;
}

.entry-content li {
  color: #111827;
  line-height: 1.625;
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.entry-content blockquote {
  background-color: #f9fafb;
	font-style: italic;
  border-left: 3px solid #e5e7eb;
  padding: 1.25rem 1.5rem;
  margin: 2rem 0;
  border-radius: 0 0.375rem 0.375rem 0;
}

.entry-content blockquote p:last-child {
  margin-bottom: 0;
}

.entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: 0.5rem;
}

.entry-content figure {
  margin-bottom: 3rem;
}

.entry-content figcaption {
  font-size: 0.875rem;
  color: #6b7280;
  margin-top: 0.5rem;
}

.entry-content strong {
  font-weight: 600;
}

.entry-content em {
  font-style: italic;
}


/* ════════════════════════════════════════
   13. WEBBKARTA
   ════════════════════════════════════════ */

.sitemap {
  margin-block: 2rem;
}

.sitemap-section {
  margin-block-end: 2rem;
}

.sitemap-section h2 {
  margin-block-end: 0.5rem;
}

.sitemap-section ul {
  list-style: none;
  padding-inline-start: 0;
}

.sitemap-section ul ul {
  padding-inline-start: 1.5rem;
  margin-block: 0.25rem;
}

.sitemap-section li {
  padding-block: 0.2rem;
}

.sitemap-meta {
  border-block-start: 1px solid #e2e8f0;
  padding-block-start: 1.5rem;
  margin-block-start: 2rem;
  color: #718096;
}

.sitemap-meta a {
  color: #718096;
  text-decoration: underline;
}


/* ════════════════════════════════════════
   14. SIDFOT
   ════════════════════════════════════════ */

.site-footer {
  border-top: 1px solid #e5e7eb;
  background-color: #f9fafb;
  margin-top: 2.5rem;
}

.site-footer h2 {
  font-size: 0.85rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: #111827;
  margin-bottom: 0.75rem;
}

.site-footer a {
  color: #4b5563;
  text-decoration: none;
}

.site-footer a:hover {
  color: #224C80;
  text-decoration: underline;
}

/* Kolumnerna */

.site-footer-main {
  max-width: 64rem;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 2rem;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 2rem;
}

.site-footer-col ul {
  list-style: none;
}

.site-footer-col li {
  margin-bottom: 0.4rem;
}

.site-footer-col li a {
  font-size: 0.95rem;
}

/* Kontakt */

.site-footer-contact address {
  font-style: normal;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 0.75rem;
}

.site-footer-social {
  list-style: none;
  display: flex;
  gap: 1rem;
}

/* Sidspecifikt: dela + permalänk */

.site-footer-page {
  max-width: 64rem;
  margin: 0 auto;
  padding: 0 1.5rem 1.5rem;
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
  font-size: 0.9rem;
  color: #4b5563;
}

.site-footer-share a {
  margin-left: 0.5rem;
}

.site-footer-share a + a::before {
  content: "·";
  margin-right: 0.5rem;
  color: #d1d5db;
}

.site-footer-permalink a {
  margin-left: 0.3rem;
}

/* Botten */

.site-footer-bottom {
  max-width: 64rem;
  margin: 0 auto;
  padding: 1rem 1.5rem;
  border-top: 1px solid #e5e7eb;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  font-size: 0.85rem;
  color: #6b7280;
}

/* Responsivt */

@media (max-width: 767px) {
  .site-footer-main {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .site-footer-main {
    grid-template-columns: 1fr;
  }

  .site-footer-page {
    flex-direction: column;
    gap: 0.75rem;
  }

  .site-footer-bottom {
    flex-direction: column;
    gap: 0.25rem;
  }
}


/* ════════════════════════════════════════
   15. RESPONSIVT
   ════════════════════════════════════════ */

/* ── Desktop (≥ 768px) ── */

@media (min-width: 768px) {

  /* Header */
  .nav-desktop        { display: flex; }
  .mobile-menu-btn    { display: none; }
  .header-search      { display: block; }

  /* Innehåll */
  .content-grid       { grid-template-columns: repeat(2, 1fr); gap: 2.5rem 1.5rem; }
  .hero-image         { height: 24rem; }

  /* Blogg */
  .blog-title         { font-size: 3rem; margin-bottom: 2rem; }
  .blog-image         { height: 20rem; }
  .blog-archive-image { height: 16rem; max-width: 40rem; }

  /* Förstasida */
  .front-grid-3       { grid-template-columns: 1fr 1fr 1fr; }
  .front-grid-2       { grid-template-columns: 1fr 1fr; }
  .hero-banner-title  { font-size: 3rem; }
  .hero-poster-top,
  .hero-poster-bottom { font-size: 3.5rem; }
  .hero-poster-top    { margin-top: 40px; position: relative; left: -140px; }
  .hero-poster-bottom { position: relative; top: -100px; left: -140px; }
  .hero-banner-poster img { opacity: 1; }

  /* Sidfot */
  .footer-content-wrapper {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}

/* ── Mobil (≤ 767px) ── */

@media (max-width: 767px) {

  .main-content {
    padding-top: 1rem;
  }

  /* Hero-banners */
  .hero-banner-title  { font-size: 2rem; }
  .hero-banner-content { padding: 1.5rem; }

  /* Ljus hero: overlay text på bilden istället för under */
  .hero-banner-light .hero-banner-content {
    position: absolute;
    inset: auto 0 0 0;
    padding: 1.5rem;
    padding-top: 3rem;
    background: linear-gradient(to top, rgba(255,255,255,0.95) 50%, rgba(255,255,255,0.6) 80%, transparent);
  }

  .hero-banner-light img {
    height: auto;
    aspect-ratio: 4 / 4;
    object-fit: cover;
  }

  /* Poster-hero: stående bild så att texten ryms */
  .hero-banner-poster img {
    aspect-ratio: 3 / 3;
  }

  /* Poster-text: Anton i stället för Impact på mobil */

  .hero-poster-top,
  .hero-poster-bottom {
    font-family: "Barlow Condensed", sans-serif;
    font-weight: 900;
    font-style: italic;
    font-stretch: wider;
    font-size: 2.9rem;
    letter-spacing: 0.4px;
    text-align: right;
  }


  .hero-banner-poster .hero-banner-content { padding: 1.8rem; }

  /* Grid till en kolumn */
  .battery-grid       { grid-template-columns: 1fr; }
  .guidance-grid      { grid-template-columns: 1fr; }
}


/* ════════════════════════════════════════
   16. UTSKRIFT — A5-BROSCHYR
   Guider och inlägg → PDF via Ctrl+P
   Förstasida: helbild + rubrik
   ════════════════════════════════════════ */

@media print {

  /* ── Sidformat ── */

  @page {
    size: A5 portrait;
    margin: 22mm 12mm 22mm;
  }

  /* Förstasidan: bryt ut ur sidmarginalerna för helbild */
  @page :first {
    margin: 0;
  }

  /* ── Dölj webbgränssnitt ── */

  .header,
  .nav-mobile,
  .footer,
  .breadcrumbs,
  .mobile-menu-btn,
  .contact-box,
  .site-footer,
  #wpadminbar {
    display: none !important;
  }

  /* ── Nollställ layout ── */

  body {
    margin: 0;
    padding: 0;
    background: #fff;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
                 "Helvetica Neue", Arial, sans-serif;
    font-size: 9.5pt;
    line-height: 1.65;
    color: #000;
  }

  .page-wrapper {
    min-height: auto;
  }

  .main-content {
    max-width: none;
    margin: 0;
    padding: 0;
  }

  .blog-post {
    max-width: none;
  }

  /* ── FÖRSTASIDA: helbild + rubrik ── */

  .blog-image-container {
    position: relative;
    width: 148mm;
    height: 210mm;
    margin: 0;
    overflow: hidden;
    page-break-after: always;
  }

  .blog-image {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
  }

  article.blog-post {
    position: relative;
  }

  .blog-title {
    position: absolute;
    top: 164mm;
    left: 10mm;
    right: 10mm;
    z-index: 2;
    font-size: 26pt;
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -1px;
    color: #fff;
    margin: 0;
  }

  /* samio.se under rubriken */
  .blog-image-container::after {
    content: "samio.se - fri energi";
    position: absolute;
    bottom: 12mm;
    left: 10mm;
    z-index: 1;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
    font-size: 8.5pt;
    color: rgba(255, 255, 255, 1);
  }

  /* ── INSIDOR ── */

  .entry-content {
    padding-top: 65mm;
    margin-right: 40px;
    margin-left: 40px;
  }

  .entry-content h2 {
    font-size: 18pt;
    font-weight: 800;
    line-height: 1.4;
    letter-spacing: -0.4px;
    color: #000;
    margin-top: 1.2em;
    margin-bottom: 0.6em;
    padding-top: 40px;
    page-break-before: always;
  }

  .entry-content p {
    font-size: 12.5pt;
    line-height: 1.65;
    color: #000;
    margin-bottom: 0.7em;
    orphans: 3;
    widows: 3;
  }

  .entry-content strong {
    font-weight: 700;
  }

  .entry-content h3 {
    font-size: 11pt;
    font-weight: 700;
    color: #000;
    margin-top: 1em;
    margin-bottom: 0.3em;
    page-break-after: avoid;
  }

  .entry-content figure {
    page-break-inside: avoid;
    padding-top: 8mm;
  }

  .entry-content img {
    max-width: 100%;
    height: auto;
    border-radius: 0;
  }

  .entry-content figcaption {
    font-size: 7.5pt;
    color: #555;
    margin-top: 0.25em;
    font-style: italic;
  }

  .entry-content ol,
  .entry-content ul {
    margin-bottom: 1em;
    padding-left: 1.5em;
  }

  .entry-content li {
    font-size: 12.5pt;
    line-height: 1.65;
    color: #000;
    margin-bottom: 0.4em;
    page-break-inside: avoid;
  }

  .entry-content blockquote {
	  font-style: italic;
    border-left: 2pt solid #999;
    padding: 0.5em 1em;
    margin: 1em 0;
    page-break-inside: avoid;
  }

  .entry-content .wp-block-separator {
    border: none;
    border-top: 0.5pt solid #ccc;
    margin: 1.5em 0;
  }

  .entry-content #skillnaden {
    page-break-before: always;
    margin: 1.5em 0;
    padding-top: 8mm;
  }

  /* ── Länkar ── */

  .entry-content a {
    color: #000;
    text-decoration: underline;
  }

  .entry-content a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-size: 7pt;
    color: #666;
    font-style: italic;
    word-break: break-all;
  }

  .entry-content a[href^="https://samio.se"]::after,
  .entry-content a[href^="/"]::after {
    content: none;
  }

  .entry-content a:has(img)::after {
    content: none;
  }

  /* ── Copyrightbilder: dölj ── */

  .entry-content figure.copyright {
    display: none;
  }

  /* ── Nedladdning: dölj ── */

  #ladda-ner {
    display: none;
  }

  /* ── Sidfot sist i broschyren ── */

  .blog-post::after {
    content: "samio.se — fri energi";
    display: block;
    margin-top: 2em;
    padding-top: 0.6em;
    border-top: 0.5pt solid #ccc;
    font-size: 7.5pt;
    color: #999;
    text-align: center;
  }

  .postid-6572 .blog-title {
    width: 100%;
    background: #fff;
    color: #333;
  }
}


/* ════════════════════════════════════════
   17. KONTAKTRUTA
   ════════════════════════════════════════ */

.contact-box {
  background-color: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 0.5rem;
  padding: 1.25rem;
  margin-top: 2.5rem;
}

.contact-box-title {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin-bottom: 0.75rem;
}

.contact-box-details {
  font-style: normal;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.contact-box-details p {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  color: #111827;
}

.contact-box-icon {
  color: #6b7280;
  flex-shrink: 0;
}

.contact-box a {
  color: #224C80;
  text-decoration: none;
}

.contact-box a:hover {
  text-decoration: underline;
}

/* ── Sidolayout på desktop ── */

@media (min-width: 768px) {
  .main-content:has(.contact-box) {
    display: grid;
    grid-template-columns: 1fr 16rem;
    gap: 2rem;
    align-items: start;
  }

  .contact-box {
    width: 16rem;
    margin-top: 6rem;
    position: sticky;
    top: 5rem;
  }
}