/* InPost Default theme styles (Loom L4.1).
   Migrated verbatim from the classic app/Views/front/layout.php <style>
   block + the home.php styles section. Customizer overrides land as
   :root CSS variables from the engine (saved mods only — theme defaults
   live here, FAZ 2 decision #3). */

:root { --ink: #1a2233; --muted: #6b7689; --line: #e6e8ee; --accent: #206bc4; }
* { box-sizing: border-box; }
body { margin: 0; color: var(--ink); font: 16px/1.7 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; background: #fff; }
.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap { max-width: 860px; margin: 0 auto; padding: 18px 20px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.site-header a { color: var(--ink); text-decoration: none; }
.site-brand { font-weight: 600; font-size: 1.1rem; }
.menu, .menu ul { list-style: none; margin: 0; padding: 0; }
.menu { display: flex; gap: 20px; align-items: center; }
.menu li { position: relative; }
.menu > li > a { font-weight: 500; }
.menu ul { position: absolute; top: 100%; left: 0; background: #fff; border: 1px solid var(--line); border-radius: 8px; padding: 6px 0; min-width: 180px; display: none; box-shadow: 0 8px 24px rgba(0,0,0,.08); z-index: 20; }
.menu li:hover > ul { display: block; }
.menu ul li a { display: block; padding: 6px 16px; }
.menu a:hover { color: var(--accent); }
@media (max-width: 600px) { .menu { gap: 12px; flex-wrap: wrap; } .menu ul { position: static; display: block; border: 0; box-shadow: none; padding-left: 12px; min-width: 0; } }
main { max-width: 860px; margin: 0 auto; padding: 40px 20px 80px; }
h1 { font-size: 2.1rem; line-height: 1.2; margin: 0 0 .6em; }
h2, h3 { line-height: 1.3; margin-top: 1.6em; }
img { max-width: 100%; height: auto; border-radius: 8px; }
.featured { width: 100%; object-fit: cover; margin-bottom: 28px; }
.content > :first-child { margin-top: 0; }
a { color: var(--accent); }
blockquote { margin: 1.5em 0; padding: .4em 1.2em; border-left: 3px solid var(--line); color: var(--muted); }
pre { background: #f6f7f9; padding: 1em; border-radius: 8px; overflow: auto; }
.content figure { margin: 1.5em 0; }
.content figcaption { margin-top: .5em; color: var(--muted); font-size: .9rem; text-align: center; }
.in-content-quote { margin: 1.5em 0; }
.in-content-quote blockquote { margin: 0; }
.in-content-quote figcaption { margin-top: .6em; padding-left: 1.2em; color: var(--muted); font-size: .92rem; text-align: left; font-style: normal; }
.in-content-quote figcaption::before { content: "\2014\00a0"; }
.in-content-image img { width: 100%; display: block; }
.in-content-image.is-width-25 { width: 25%; }
.in-content-image.is-width-33 { width: 33%; }
.in-content-image.is-width-50 { width: 50%; }
.in-content-image.is-width-66 { width: 66%; }
.in-content-image.is-width-75 { width: 75%; }
.in-content-image.is-width-100, .in-content-image.is-align-wide, .in-content-image.is-align-full { width: 100%; }
.in-content-image.is-align-left { float: left; margin: .35em 1.4em 1em 0; }
.in-content-image.is-align-right { float: right; margin: .35em 0 1em 1.4em; }
.in-content-image.is-align-center, .in-content-image.is-align-wide, .in-content-image.is-align-full { margin-left: auto; margin-right: auto; }
.in-content-media { margin: 1.5em 0; }
.in-content-media::after { content: ""; display: block; clear: both; }
.in-content-media .in-content-image { margin-top: 0; }
.in-content-media-body > :first-child { margin-top: 0; }
.in-content-media-body > :last-child { margin-bottom: 0; }
.in-align-left { text-align: left; }
.in-align-center { text-align: center; }
.in-align-right { text-align: right; }
.in-content-media.is-boxed { padding: 1.25em; border: 1px solid var(--line); border-radius: 12px; background: #f8fafc; }
.in-content-image.is-zoomable img { cursor: zoom-in; }
.in-lightbox { position: fixed; inset: 0; z-index: 9999; display: flex; align-items: center; justify-content: center; padding: 4vmin; background: rgba(15,18,25,.82); cursor: zoom-out; }
.in-lightbox img { max-width: 100%; max-height: 100%; border-radius: 8px; box-shadow: 0 10px 40px rgba(0,0,0,.4); }
.in-content-delimiter { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }
.in-content-table { width: 100%; border-collapse: collapse; margin: 1.5em 0; overflow-wrap: anywhere; }
.in-content-table th, .in-content-table td { border: 1px solid var(--line); padding: .65em .75em; vertical-align: top; }
.in-content-table th { background: #f6f7f9; text-align: left; }
.in-content-checklist { list-style: none; padding-left: 0; }
.in-content-checklist li { position: relative; padding-left: 1.75em; margin: .45em 0; }
.in-content-checklist li::before { content: ""; position: absolute; left: 0; top: .25em; width: 1.1em; height: 1.1em; border: 1px solid var(--line); border-radius: .3em; }
.in-content-checklist li.is-checked::before { background: var(--accent); border-color: var(--accent); }
.in-content-checklist li.is-checked::after { content: ""; position: absolute; left: .36em; top: .45em; width: .35em; height: .6em; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.in-content-callout { border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 10px; background: #f8fafc; padding: 1em 1.1em; margin: 1.5em 0; }
.in-content-callout.is-warning { border-left-color: #f59f00; }
.in-content-callout.is-danger { border-left-color: #d6336c; }
.in-content-callout.is-success { border-left-color: #2f9e44; }
.in-content-callout-title { display: block; margin-bottom: .35em; color: var(--ink); }
.in-content-columns { display: grid; gap: 1.25rem; margin: 1.5em 0; }
.in-content-columns.is-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.in-content-columns.is-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.in-content-code code { white-space: pre; }
.in-content-embed iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 10px; background: #f1f3f5; }
.in-content-link-card a, .in-content-embed.is-link a { display: block; border: 1px solid var(--line); border-radius: 10px; padding: 1em; color: var(--ink); text-decoration: none; }
.in-content-link-card strong { display: block; }
.in-content-link-card small { display: block; margin-top: .35em; color: var(--muted); }
@media (max-width: 700px) {
    .in-content-image.is-align-left, .in-content-image.is-align-right { float: none; width: 100%; margin: 1.5em 0; }
    .in-content-image.is-width-25, .in-content-image.is-width-33, .in-content-image.is-width-50, .in-content-image.is-width-66, .in-content-image.is-width-75 { width: 100%; }
    .in-content-columns.is-2, .in-content-columns.is-3 { grid-template-columns: 1fr; }
}
.pw-gate { max-width: 420px; margin: 8vh auto; }
.pw-gate input { width: 100%; padding: 10px 12px; font-size: 1rem; border: 1px solid var(--line); border-radius: 8px; }
.pw-gate button { margin-top: 12px; padding: 10px 18px; font-size: 1rem; color: #fff; background: var(--accent); border: 0; border-radius: 8px; cursor: pointer; }
.pw-error { color: #d63939; }
.preview-bar { background: #f59f00; color: #1a2233; text-align: center; padding: 8px 16px; font-size: .9rem; font-weight: 600; }
.in-slider { position: relative; overflow: hidden; }
.in-slide { display: none; position: relative; }
.in-slide.is-active { display: block; }
.in-slide img { width: 100%; height: auto; display: block; border-radius: 0; }
.in-slide-caption { position: absolute; left: 0; right: 0; bottom: 0; padding: 24px 28px; background: linear-gradient(transparent, rgba(0,0,0,.65)); color: #fff; }
.in-slide-caption h2 { margin: 0 0 .2em; color: #fff; }
.in-slide-caption p { margin: 0; opacity: .9; }
.in-slide-btn { display: inline-block; margin-top: 12px; background: var(--accent); color: #fff; padding: 8px 18px; border-radius: 8px; text-decoration: none; }
.in-slider-prev, .in-slider-next { position: absolute; top: 50%; transform: translateY(-50%); background: rgba(255,255,255,.85); border: 0; width: 40px; height: 40px; border-radius: 50%; font-size: 22px; line-height: 1; cursor: pointer; color: var(--ink); }
.in-slider-prev { left: 12px; } .in-slider-next { right: 12px; }
.in-slider-dots { position: absolute; bottom: 14px; left: 50%; transform: translateX(-50%); display: flex; gap: 6px; }
.in-dot { width: 9px; height: 9px; padding: 0; border-radius: 50%; border: 0; background: rgba(255,255,255,.6); cursor: pointer; }
.in-dot.is-active { background: #fff; }
.text-muted { color: var(--muted); }
.products-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 20px; margin-top: 24px; }
.product-card { display: block; text-decoration: none; color: var(--ink); border: 1px solid var(--line); border-radius: 10px; overflow: hidden; transition: box-shadow .15s; }
.product-card:hover { box-shadow: 0 8px 24px rgba(0,0,0,.08); }
.product-card img, .product-noimg { display: block; width: 100%; aspect-ratio: 1; object-fit: cover; background: #f1f3f5; border-radius: 0; }
.product-card .product-name { display: block; padding: 10px 12px 0; font-weight: 600; }
.product-card .product-price { display: block; padding: 2px 12px 12px; color: var(--muted); }
.sale { color: #d6336c; font-weight: 600; } .was { text-decoration: line-through; color: var(--muted); margin-right: 6px; font-weight: 400; }
.product-single { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
@media (max-width: 700px) { .product-single { grid-template-columns: 1fr; } }
.product-media .main-img { width: 100%; border-radius: 12px; }
.product-thumbs { display: flex; gap: 8px; margin-top: 10px; flex-wrap: wrap; }
.product-thumbs img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; cursor: pointer; border: 2px solid transparent; }
.product-thumbs img.is-active { border-color: var(--accent); }
.product-main-wrap { position: relative; }
.product-media-nav { display: none; position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 38px; height: 38px; border: 0; border-radius: 50%; background: rgba(255,255,255,.88); color: var(--ink); font-size: 1.6rem; cursor: pointer; }
.product-gallery-slider .product-media-nav { display: inline-flex; align-items: center; justify-content: center; }
.product-media-prev { left: 10px; } .product-media-next { right: 10px; }
.product-info .price { font-size: 1.6rem; font-weight: 700; margin: .1em 0 .5em; }
.product-info .price .was { font-size: 1.1rem; }
.product-info .lead { font-size: 1.05rem; color: var(--muted); }
.product-cats a { margin-right: 8px; }
.product-options { display: grid; gap: 18px; margin: 24px 0; }
.product-option-group-front label { display: block; font-weight: 700; margin-bottom: 6px; }
.product-option-group-front p { margin: 0 0 10px; color: var(--muted); font-size: .92rem; }
.product-option-group-front select { width: 100%; border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; background: #fff; font: inherit; }
.product-option-values-front { display: flex; flex-wrap: wrap; gap: 8px; }
.product-option-choice { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); border-radius: 10px; background: #fff; padding: 8px 12px; color: var(--ink); cursor: pointer; font: inherit; }
.product-option-choice.is-active { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(32,107,196,.12); }
.product-option-choice img { width: 34px; height: 34px; object-fit: cover; border-radius: 6px; }
.product-swatch { width: 18px; height: 18px; border-radius: 50%; background: var(--swatch, var(--accent)); border: 1px solid rgba(0,0,0,.12); }
.product-specs { margin-top: 32px; }
.product-specs h2 { margin: 0 0 12px; font-size: 1.2rem; }
.product-specs-table { width: 100%; border-collapse: collapse; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.product-specs-table tr + tr { border-top: 1px solid var(--line); }
.product-specs-table th, .product-specs-table td { padding: 11px 14px; text-align: left; vertical-align: top; font-size: .95rem; }
.product-specs-table th { width: 38%; font-weight: 700; color: var(--ink); background: rgba(0,0,0,.025); }
.product-specs-table td { color: var(--muted); }
.product-documents { margin-top: 32px; display: grid; gap: 10px; }
.product-documents h2 { margin: 0 0 4px; font-size: 1.2rem; }
.product-document-link { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; text-decoration: none; color: var(--ink); }
.product-document-link:hover { border-color: var(--accent); }
.product-document-link small { color: var(--muted); font-weight: 700; }
.header-right { display: flex; align-items: center; gap: 20px; }
.lang-switcher { display: flex; gap: 4px; }
.lang-link { font-size: .8rem; font-weight: 600; padding: 2px 8px; border-radius: 6px; color: var(--muted); text-decoration: none; }
.lang-link.is-active { background: var(--accent); color: #fff; }
.site-footer { border-top: 1px solid var(--line); margin-top: 64px; background: #fafbfc; }
.site-footer .wrap { max-width: 860px; margin: 0 auto; padding: 28px 20px; }
.site-footer .menu { gap: 18px; margin-bottom: 12px; flex-wrap: wrap; }
.site-footer .menu a { color: var(--muted); font-weight: 500; }
.site-footer .menu a:hover { color: var(--accent); }
.footer-copy { color: var(--muted); font-size: .9rem; }
/* RTL: mirror structural left/right for right-to-left locales (Arabic, …).
   Scoped to [dir=rtl] so LTR rendering is untouched. Author-chosen
   alignment (is-align-left/right) intentionally stays put. */
[dir="rtl"] .menu ul { left: auto; right: 0; }
[dir="rtl"] blockquote { border-left: 0; border-right: 3px solid var(--line); }
[dir="rtl"] .in-content-quote figcaption { padding-left: 0; padding-right: 1.2em; text-align: right; }
[dir="rtl"] .in-content-table th { text-align: right; }
[dir="rtl"] .in-content-checklist { padding-right: 0; }
[dir="rtl"] .in-content-checklist li { padding-left: 0; padding-right: 1.75em; }
[dir="rtl"] .in-content-checklist li::before { left: auto; right: 0; }
[dir="rtl"] .in-content-checklist li.is-checked::after { left: auto; right: .36em; }
[dir="rtl"] .in-content-callout { border-left: 1px solid var(--line); border-right: 4px solid var(--accent); }
[dir="rtl"] .in-content-callout.is-warning { border-right-color: #f59f00; }
[dir="rtl"] .in-content-callout.is-danger { border-right-color: #d6336c; }
[dir="rtl"] .in-content-callout.is-success { border-right-color: #2f9e44; }
[dir="rtl"] .in-slider-prev { left: auto; right: 12px; }
[dir="rtl"] .in-slider-next { right: auto; left: 12px; }
[dir="rtl"] .product-media-prev { left: auto; right: 10px; }
[dir="rtl"] .product-media-next { right: auto; left: 10px; }
[dir="rtl"] .was { margin-right: 0; margin-left: 6px; }
[dir="rtl"] .product-cats a { margin-right: 0; margin-left: 8px; }
@media (max-width: 600px) { [dir="rtl"] .menu ul { padding-left: 0; padding-right: 12px; } }

/* Home (composed landing) */
.home-hero { text-align: center; padding: 64px 20px; background: linear-gradient(180deg, #f8fafc, #fff); border-bottom: 1px solid var(--line); margin: -40px -20px 0; }
.home-hero h1 { font-size: 2.6rem; margin: 0 0 .3em; }
.home-hero p { color: var(--muted); font-size: 1.15rem; max-width: 620px; margin: 0 auto 1.4em; }
.home-hero .btn { display: inline-block; margin: 0 6px; padding: 11px 22px; border-radius: 8px; text-decoration: none; font-weight: 600; }
.home-hero .btn-primary { background: var(--accent); color: #fff; }
.home-hero .btn-ghost { border: 1px solid var(--line); color: var(--ink); }
.home-section { margin-top: 52px; }
.home-section-head { display: flex; align-items: baseline; justify-content: space-between; margin-bottom: 18px; }
.home-section-head h2 { margin: 0; font-size: 1.5rem; }
.home-section-head a { font-weight: 600; }
.post-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 24px; }
.post-mini { border: 1px solid var(--line); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; }
.post-mini img { aspect-ratio: 16/9; object-fit: cover; background: #f1f3f5; }
.post-mini .body { padding: 14px 16px; }
.post-mini h3 { margin: 0 0 .3em; font-size: 1.05rem; line-height: 1.3; }
.post-mini h3 a { color: var(--ink); text-decoration: none; }
.post-mini p { color: var(--muted); margin: 0 0 .5em; font-size: .92rem; }

/* Blog skins (module: inpost/blog — L4.2) */
.blog-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 28px; margin-top: 24px; }
.blog-card { border: 1px solid var(--line); border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; }
.blog-card .thumb { display: block; aspect-ratio: 16/9; object-fit: cover; background: #f1f3f5; width: 100%; }
.blog-card .body { padding: 16px 18px; display: flex; flex-direction: column; gap: 8px; }
.blog-card h2 { font-size: 1.15rem; margin: 0; line-height: 1.3; }
.blog-card h2 a { color: var(--ink); text-decoration: none; }
.blog-card .date { color: var(--muted); font-size: .85rem; }
.blog-card .tax { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 2px; }
.blog-card .tax a { border: 1px solid var(--line); border-radius: 6px; color: var(--muted); font-size: .78rem; padding: 1px 7px; text-decoration: none; }
.blog-card .excerpt { color: var(--muted); margin: 0; }
.blog-card .more { margin-top: auto; font-weight: 600; }
.blog-intro { color: var(--muted); }
.blog-pager { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 28px; }
.blog-pager a, .blog-pager span { border: 1px solid var(--line); border-radius: 8px; padding: 7px 11px; text-decoration: none; }
.blog-pager .is-disabled { color: var(--muted); opacity: .55; }
.blog-pager .is-ellipsis { border-color: transparent; color: var(--muted); }
.blog-pager .is-current { background: var(--ink); color: #fff; border-color: var(--ink); }
.post-meta { color: var(--muted); margin-bottom: 20px; }
.post-meta a { color: var(--accent); }
.post-featured { width: 100%; border-radius: 12px; margin-bottom: 28px; object-fit: cover; }
.post-tags { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--muted); }
.post-tags .tag { display: inline-block; background: #f1f3f5; border-radius: 6px; padding: 2px 10px; margin: 0 4px 4px 0; font-size: .85rem; text-decoration: none; color: inherit; }

/* --- Section Builder sections (Loom L6.3) ---------------------------------- */
.df-section { margin: 48px 0; }
.df-section:first-child { margin-top: 0; }
.df-section-title { margin: 0 0 20px; font-size: 1.5rem; }
.df-hero { padding: 40px 28px; border: 1px solid var(--line); border-radius: 16px; background: #f8f9fb; }
.df-hero-center { text-align: center; }
.df-hero-image { width: 100%; max-height: 320px; object-fit: cover; border-radius: 12px; margin-bottom: 24px; }
.df-hero-title { margin: 0 0 .4em; font-size: 2rem; line-height: 1.2; }
.df-hero-body { color: var(--muted); max-width: 560px; }
.df-hero-center .df-hero-body { margin-left: auto; margin-right: auto; }
.df-hero-actions { margin: 24px 0 0; }
.df-features-grid { display: grid; gap: 18px; grid-template-columns: repeat(3, 1fr); }
.df-cols-2 { grid-template-columns: repeat(2, 1fr); }
.df-cols-4 { grid-template-columns: repeat(4, 1fr); }
.df-feature { border: 1px solid var(--line); border-radius: 12px; padding: 20px; }
.df-feature h3 { margin: 0 0 .5em; font-size: 1.05rem; }
.df-feature-text { color: var(--muted); font-size: .95rem; }
.df-feature-text > :first-child { margin-top: 0; }
.df-feature-text > :last-child { margin-bottom: 0; }
.df-cta { text-align: center; padding: 8px 0; }
.df-cta-boxed { background: var(--ink); color: #fff; border-radius: 16px; padding: 40px 28px; }
.df-cta-title { margin: 0 0 .8em; font-size: 1.6rem; }
.df-cta-boxed .btn-primary { background: #fff; color: var(--ink); }
@media (max-width: 700px) { .df-features-grid, .df-cols-2, .df-cols-4 { grid-template-columns: 1fr; } }
