/* ==========================================================================
   COMPONENT STATES — Figma "Buttons" / "Forms" component sheets (970:1528, 970:1527,
   3049:1239 dev note). Hover (pointer) and keyboard focus use the Figma "Focused" variant.
   Loaded LAST on every page, so these win over the older per-page hover rules.
     Hover Glow/Pumpkin = drop shadow 0 8 10 #FF740033 + inner shadow 50 50 80 #EEECE91A
     Hover Glow/White   = inner shadow 50 50 80 #FFFFFF33
   ========================================================================== */
:root {
  --glow-pumpkin: 0 8px 10px 0 rgba(255,116,0,.2), inset 50px 50px 80px 0 rgba(238,236,233,.1);
  --ease-ui: cubic-bezier(.22,.61,.36,1);
}

/* ---- smooth, shared transitions ---- */
.btn, .ham, .news-more, .news-arrow, .round-btn, .form-submit, .nm-cta, .nm-notify, .doc-dl, .doc-link,
.footer-social a, .faq-item summary::after, .istep-btn, .cenik-item summary::after, .field {
  transition: background-color .3s var(--ease-ui), border-color .3s var(--ease-ui), box-shadow .3s var(--ease-ui),
              color .3s var(--ease-ui), opacity .3s var(--ease-ui), transform .35s var(--ease-ui);
}
/* arrows glide diagonally instead of snapping */
.btn svg, .cta-arrow, .nm-arrow, .ma-arrow, .news-more svg, .contact-meta .vp img, .doc-link img {
  transition: transform .4s var(--ease-ui), translate .4s var(--ease-ui), opacity .3s var(--ease-ui);
}
/* Textlink-Icon (Figma 985:2713): the exported arrow points up-left; the instance mirrors it so it points up-right */
.doc-link img, .contact-meta .vp img { scale: -1 1; }   /* ic-extlink.svg points up-left: mirrored so the arrow points up-right like the other links */

@media (hover: hover) {
  /* ---- CTA Primary (Focused) ---- */
  html .btn-primary:hover, html .news-more:hover, html .form-submit:hover:not(:disabled), html .nm-cta:hover, html .nm-notify:hover {
    background: #FF7400; transform: none; box-shadow: var(--glow-pumpkin);
  }
  /* ---- CTA Secondary (Focused): 10% white wash, blurred, off-white outline ---- */
  html .btn-secondary:hover {
    background: rgba(255,255,255,.1); border-color: #EBE7DC; transform: none;
    -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px);
  }
  html .hero-actions .btn-secondary:hover { background: rgba(255,255,255,.1); }
  /* arrow nudge on hover */
  .btn:hover svg, .btn:hover .cta-arrow, .nm-cta:hover .nm-arrow, .nm-notify:hover .nm-arrow, .news-more:hover svg { transform: translate(2px, -2px); }
  .contact-meta .vp:hover img { transform: translate(2px, -2px); }
  .doc-link:hover img { translate: 2px -2px; }   /* the icon is mirrored with `scale` (below), so the nudge uses `translate` to stay up-right */

  /* ---- HamMenu: Pumpkin (on the light page) / Light (on a photo hero) ---- */
  html .ham:hover {
    background: rgba(255,116,0,.2); box-shadow: var(--glow-pumpkin);
  }
  html body:not(.is-scrolled) .frame.has-hero > .site-header:not(.site-header--solid) .ham:hover {
    background: rgba(255,255,255,.1); box-shadow: none; border-color: #EBE7DC;
    -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px);
  }

  /* ---- Button.Slider (news): Border / Filled (gallery) ---- */
  html .news-arrow:hover {
    background: rgba(255,116,0,.2); border-color: rgba(255,116,0,.5); transform: none; box-shadow: var(--glow-pumpkin);
  }
  html .round-btn:hover { transform: none; box-shadow: inset 50px 50px 80px 0 rgba(255,255,255,.1); background: rgba(255,255,255,.5); }
  html .pron-arrow:hover { transform: translateY(-50%); background: rgba(255,255,255,.5); box-shadow: inset 50px 50px 80px 0 rgba(255,255,255,.1); }

  /* ---- Button.ShowInAuksys / FAQ + steps expand button (36px): Focused ---- */
  .faq-item summary:hover::after, .cenik-item summary:hover::after {
    background-color: rgba(255,116,0,.2); box-shadow: inset 0 0 0 1px rgba(255,116,0,.5), var(--glow-pumpkin);
    background-image: linear-gradient(#FF7400, #FF7400), linear-gradient(#FF7400, #FF7400);
  }
  .istep-head:hover .istep-btn, .istep-btn:hover {
    background-color: rgba(255,116,0,.2); box-shadow: inset 0 0 0 1px rgba(255,116,0,.5), var(--glow-pumpkin);
  }
  .istep-head:hover .istep-btn::before {
    background: linear-gradient(#FF7400, #FF7400) center / 14px 2px no-repeat, linear-gradient(#FF7400, #FF7400) center / 2px 14px no-repeat;
  }

  /* ---- Button.Download (Focused) ---- */
  html .doc-dl:hover {
    background: rgba(255,255,255,.1); border-color: rgba(255,255,255,.5); box-shadow: inset 50px 50px 80px 0 rgba(255,255,255,.2);
  }
  /* ---- Textlink-Icon (Focused): everything turns pumpkin ---- */
  html .doc-link:hover { color: #FF7400; border-bottom-color: #FF7400; }

  /* ---- Socials.Button (Focused): solid Bole + blur ---- */
  html .footer-social a:hover { background: #714940; -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); }

  /* ---- Footer-Link (Focused): label + 20px arrow, gap 4 ---- */
  .footer-nav { align-items: flex-start; }
  .footer-nav a { position: relative; }
  /* the arrow hangs OUTSIDE the link box, so showing it never changes the width of the nav column
     (the footer grid sizes its columns to their content — a growing link used to shift the other columns) */
  .footer-nav a::after {
    content: ''; position: absolute; left: calc(100% + 4px); bottom: 1px; width: 20px; height: 20px; pointer-events: none;
    opacity: 0; transform: translate(-4px, 4px);
    transition: opacity .3s var(--ease-ui), transform .4s var(--ease-ui);
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.4 18L5 16.6L14.6 7H6V5H18V17H16V8.4L6.4 18Z' fill='%23EBE7DC'/%3E%3C/svg%3E") center / 20px 20px no-repeat;
  }
  .footer-nav a:hover::after, .footer-nav a:focus-visible::after { opacity: 1; transform: none; }
  /* the same glide for the e-mail (hangs into the right gutter) */
  .footer-addr .mail { position: relative; }
  .footer-addr .mail::after {
    content: ''; position: absolute; left: calc(100% + 4px); bottom: 1px; width: 20px; height: 20px; pointer-events: none;
    opacity: 0; transform: translate(-4px, 4px);
    transition: opacity .3s var(--ease-ui), transform .4s var(--ease-ui);
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6.4 18L5 16.6L14.6 7H6V5H18V17H16V8.4L6.4 18Z' fill='%23EBE7DC'/%3E%3C/svg%3E") center / 20px 20px no-repeat;
  }
  .footer-addr .mail:hover::after, .footer-addr .mail:focus-visible::after { opacity: 1; transform: none; }

  /* ---- ServicesMenu rows: arrow nudges diagonally ---- */
  a.ma-item:hover .ma-arrow { transform: translate(2px, -2px); }
}

/* keyboard focus mirrors hover for the main controls */
html .btn-primary:focus-visible, html .news-more:focus-visible, html .nm-cta:focus-visible, html .form-submit:focus-visible { box-shadow: var(--glow-pumpkin); outline: none; }
html .btn-secondary:focus-visible { background: rgba(255,255,255,.1); outline: none; }
html .ham:focus-visible { background: rgba(255,116,0,.2); box-shadow: var(--glow-pumpkin); outline: none; }
html .news-arrow:focus-visible { background: rgba(255,116,0,.2); box-shadow: var(--glow-pumpkin); outline: none; }
html .doc-dl:focus-visible { background: rgba(255,255,255,.1); outline: none; }
html .doc-link:focus-visible { color: #FF7400; border-bottom-color: #FF7400; outline: none; }
html .footer-social a:focus-visible { background: #714940; outline: none; }

/* ---- Disabled (CTA Primary Disabled) ---- */
html .btn[disabled], html .btn.is-disabled, html .form-submit:disabled, html .nm-submit:disabled {
  background: rgba(255,116,0,.5); color: rgba(235,231,220,.5); box-shadow: none; transform: none; cursor: not-allowed; pointer-events: none;
}

/* ---- Forms (3049:1239 + 970:1527): radius 12, Focused = 2px orange border on a 50% white fill, Invalid = red ---- */
.field { border-radius: 12px; }
.field:focus-within { border-width: 2px; padding: 13px 15px; background: rgba(255,255,255,.5); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); }
.field.area:focus-within { padding: 13px 15px; }
.field.is-invalid { border-color: #FF3030; background: rgba(255,48,48,.1); }
.field.is-invalid input, .field.is-invalid textarea { color: #FF3030; }
.field.is-invalid ::placeholder { color: #FF3030; }
.field-error { margin: 12px 0 0; font-family: 'Ubuntu', sans-serif; font-weight: 400; font-size: 16px; line-height: 26px; letter-spacing: .08px; color: #FF3030; }
.field.area { min-height: 204px; height: auto; }
.field.area textarea { min-height: 170px; height: auto; field-sizing: content; }

/* ---- Figma 819:3513 / 819:3526 / 819:3607 / 819:3530 (Name / E-mail / Message input + Subject picker, desktop) ----
   Figma strokes sit INSIDE the 14px/16px padding, so a field is 60px high in every state (1px border + 13px padding;
   Focused 2px border + 12px padding), text 16px from the left edge, Invalid = red tint with a 7px radius and the
   message 12px under it (16px column gap - 4px). */
@media (min-width: 621px) {
  .field { padding: 13px 15px; }
  .field:focus-within, .field.area:focus-within { padding: 12px 14px; }
  .field.area { padding-top: 13px; }
  .field.area:focus-within { padding-top: 12px; }
  .field.is-invalid { border-radius: 7px; padding: 13px 15px; border-width: 1px; }
  .field.is-invalid:focus-within { padding: 13px 15px; border-width: 1px; background: rgba(255,48,48,.1); }
  .field-error { margin: -4px 0 0; }
}
/* Filled = the same 1px orange outline with a 5px blur behind it (only visible over the photo-like contact panel) */
.field:has(input:not(:placeholder-shown), textarea:not(:placeholder-shown)) { -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); }

/* Subject picker: Default / Filled / Open. The native <select> stays in the form (it is what is submitted and what the
   readiness check reads) but is visually hidden once home.js has built the button + list. */
.field.select.is-enhanced { flex-direction: column; align-items: stretch; justify-content: center; gap: 16px; position: relative; }
.field.select.is-enhanced > select { position: absolute; width: 1px; height: 1px; margin: 0; padding: 0; opacity: 0; pointer-events: none; overflow: hidden; clip: rect(0 0 0 0); }
.field .sel-btn { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 0; cursor: pointer; text-align: left; color: rgba(113,73,64,.7); }
.field .sel-label { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.field .sel-btn img { width: 24px; height: 24px; flex: 0 0 auto; transform: rotate(-90deg); }
.field.select.has-value .sel-btn { color: #402e32; }
/* in the news popup and in the contact form the open list floats over the fields below instead of pushing the layout
   (in the popup it would stretch the photo next to it, in the contact form it would shove the message box and the button down) */
.nm-form .field.select.is-enhanced, .contact-form .field.select.is-enhanced { gap: 0; }
.nm-form .field .sel-list, .contact-form .field .sel-list { position: absolute; left: -1px; right: -1px; top: calc(100% + 6px); z-index: 6; padding: 16px 15px; background: #F6F4EE; border: 1px solid var(--pumpkin); border-radius: 12px; box-shadow: 0 10px 28px rgba(64,46,50,.18); }
.nm-form .field .sel-list[hidden], .contact-form .field .sel-list[hidden] { display: none; }
.field.select.is-single .sel-btn { cursor: default; }
.field.select.is-single .sel-btn img { display: none; }
.field .sel-list { display: flex; flex-direction: column; gap: 16px; margin: 0; padding: 0; list-style: none; }
.field .sel-list[hidden] { display: none; }
.field .sel-list li { width: auto; color: #714940; cursor: pointer; transition: color .15s ease; }
.field .sel-list li:hover, .field .sel-list li:focus-visible { color: #FF7400; }
.field .sel-list li[aria-selected="true"] { color: #402e32; }
.field.select.is-open, .field.select.is-open:focus-within { border-width: 1px; padding: 13px 15px; background: rgba(255,255,255,.5); -webkit-backdrop-filter: blur(5px); backdrop-filter: blur(5px); }


/* ==========================================================================
   LIGHT MOTION — expand buttons, answers and press feedback (2026-11-19)
   ========================================================================== */
:root { interpolate-size: allow-keywords; }

/* + / × : the circle turns a quarter-turn smoothly (the + → × is a 45° rotation) and breathes on hover/press */
.istep-btn::before { transition: transform .4s var(--ease-ui); }
.faq-item summary::after, .cenik-item summary::after, .istep-btn { transition: transform .4s var(--ease-ui), background-color .3s var(--ease-ui), box-shadow .3s var(--ease-ui); }
@media (hover: hover) {
  .faq-item summary:hover::after, .cenik-item summary:hover::after { transform: scale(1.08); }
  .faq-item[open] summary:hover::after, .cenik-item[open] summary:hover::after { transform: rotate(45deg) scale(1.08); }
  .istep-head:hover .istep-btn { transform: scale(1.08); }
}
.faq-item summary:active::after, .cenik-item summary:active::after { transform: scale(.92); }
.faq-item[open] summary:active::after, .cenik-item[open] summary:active::after { transform: rotate(45deg) scale(.92); }
.istep-head:active .istep-btn { transform: scale(.92); }

/* answers slide open / closed instead of snapping (Chrome/Safari 17.4+; elsewhere they simply appear) */
@supports selector(::details-content) {
  .faq-item::details-content, .istep::details-content, .cenik-item::details-content {
    block-size: 0; overflow: hidden; opacity: 0;
    transition: block-size .4s var(--ease-ui), opacity .3s ease, content-visibility .4s allow-discrete;
  }
  .faq-item[open]::details-content, .istep[open]::details-content, .cenik-item[open]::details-content { block-size: auto; opacity: 1; }
}

/* a soft press on every button */
html .btn:active, html .ham:active, html .news-more:active, html .news-arrow:active, html .round-btn:active,
html .form-submit:active, html .nm-cta:active, html .nm-notify:active, html .doc-dl:active, html .footer-social a:active { transform: scale(.97); }

@media (prefers-reduced-motion: reduce) {
  .faq-item::details-content, .istep::details-content, .cenik-item::details-content,
  .faq-item summary::after, .istep-btn, .istep-btn::before { transition: none !important; }
  html .btn:active, html .ham:active, html .news-more:active, html .news-arrow:active, html .round-btn:active,
  html .form-submit:active, html .nm-cta:active, html .nm-notify:active, html .doc-dl:active { transform: none; }
}


/* ---- contact form: honeypot (off-screen, bots fill it) and the status line after sending ---- */
.hp-field { position: absolute !important; left: -9999px; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.form-status { margin: 16px 0 0; font-family: 'Ubuntu', sans-serif; font-weight: 400; font-size: 16px; line-height: 26px; letter-spacing: .08px; color: #714940; }
.form-status.is-error { color: #FF3030; }
.contact-form.is-sending .form-submit { pointer-events: none; opacity: .6; }


/* ---- touch screens (tablets, phones): bigger tap area for small text links, without changing the layout ----
   an invisible pseudo-element extends the clickable box to ~44px (footer links are 22px high, textlinks 32px) */
@media (pointer: coarse) {
  .footer-nav a, .footer-addr .mail, .doc-link { position: relative; }
  .footer-nav a::before, .footer-addr .mail::before, .doc-link::before { content: ''; position: absolute; inset: -8px -6px; }
  .doc-link::before { inset: -6px -4px; }
}
