@font-face {
  font-family: "icons";
  src: url("../assets/icons.woff") format("woff");
  font-weight: normal;
  font-style: normal;
  font-display: block;
}

:root {
  --yellow: #ffcc05;
  --yellow-hover: #f2c000;
  --ink: #3c3c3c;
  --blue: #1d4e89;
  --red: #e30613;
  --footer-bg: #f3f3f3;
  --panel-bg: #ededed;
  --line: #dcdcdc;
  --radius: 4px;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: Montserrat, "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.45;
  color: var(--ink);
  background: #fff;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

button {
  font: inherit;
  color: inherit;
}

.icon {
  font-family: "icons";
  font-style: normal;
  font-weight: normal;
  line-height: 1;
  speak: none;
}

/* Header */
.header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: #fff;
  border-bottom: 1px solid var(--line);
}

.header__inner {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 82px;
  padding: 0 0 0 26px;
  gap: 10px;
}

.burger {
  position: relative;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  background: none;
  cursor: pointer;
  flex: 0 0 auto;
}

.burger span {
  position: absolute;
  left: 2px;
  width: 32px;
  height: 4px;
  border-radius: 2px;
  background: #1d1d1d;
  transition: transform 0.2s ease, opacity 0.2s ease, top 0.2s ease;
}

.burger span:nth-child(1) { top: 7px; }
.burger span:nth-child(2) { top: 16px; }
.burger span:nth-child(3) { top: 25px; }

.burger[aria-expanded="true"] span:nth-child(1) { top: 16.5px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { top: 16.5px; transform: rotate(-45deg); }

.header__logo {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
}

.header__logo img {
  width: 78px;
  height: auto;
}

.header__track {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  padding-right: 24px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.15;
  text-decoration: none;
  flex: 0 0 auto;
}

.header__track svg {
  width: 26px;
  height: 28px;
  flex: 0 0 auto;
}

/* Menu drawer */
.drawer {
  position: fixed;
  inset: 82px 0 0;
  z-index: 15;
  display: none;
  overflow-y: auto;
  padding: 18px 24px 32px;
  background: #fff;
}

.drawer.is-open {
  display: block;
}

.drawer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.drawer a {
  display: block;
  padding: 13px 0;
  border-bottom: 1px solid #eee;
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
}

.drawer a:hover {
  color: var(--blue);
}

.backdrop {
  position: fixed;
  inset: 82px 0 0;
  z-index: 14;
  display: none;
  background: rgba(0, 0, 0, 0.35);
}

.backdrop.is-open {
  display: block;
}

/* Layout */
.main {
  padding: 0 12px 48px;
}

.panel-page {
  padding-top: 0;
}

.page-title {
  margin: 64px 0 40px;
  font-size: 27px;
  font-weight: 700;
  line-height: 1.2;
  text-align: center;
  color: var(--blue);
}

.panel {
  padding: 16px 14px 22px;
  background: var(--panel-bg);
}

.parcel-number {
  margin: 0 0 10px;
  font-size: 18px;
}

.notice-title {
  margin: 0 0 8px;
  font-size: 18px;
  font-weight: 700;
  color: var(--red);
}

.notice-list {
  margin: 0 0 26px;
  padding-left: 18px;
  font-size: 17px;
  line-height: 1.55;
}

.notice-list li + li {
  margin-top: 10px;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 15px 26px;
  border: 0;
  border-radius: var(--radius);
  font-size: 16px;
  font-weight: 400;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  background: var(--yellow);
  color: #1d1d1d;
}

.btn:hover,
.btn:focus-visible {
  background: var(--yellow-hover);
}

.btn--outline {
  border: 2px solid var(--yellow);
  background: #fff;
  padding: 13px 24px;
  font-weight: 700;
}

.btn--outline:hover,
.btn--outline:focus-visible {
  background: var(--yellow);
}

.btn--block {
  width: 100%;
}

/* Address form */
.form-intro {
  margin: 0 0 22px;
  font-size: 17px;
  line-height: 1.45;
}

.form-heading {
  margin: 48px 0 22px;
  font-size: 34px;
  font-weight: 700;
  line-height: 1.15;
  color: #3c3c3c;
}

.field {
  margin-bottom: 18px;
}

.field label,
.field-label {
  display: block;
  margin-bottom: 6px;
  font-size: 17px;
  font-weight: 400;
}

.field-label {
  margin-bottom: 8px;
}

.field input,
.field select {
  width: 100%;
  height: 46px;
  padding: 0 12px;
  border: 1px solid #c4c4c4;
  border-radius: var(--radius);
  background: #fff;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
}

.field input::placeholder {
  color: #a7a7a7;
}

.field input:focus,
.field select:focus {
  outline: 2px solid #8fb0d6;
  outline-offset: 1px;
  border-color: #8fb0d6;
}

.field.has-error input {
  border-color: var(--red);
}

.field-error {
  display: none;
  margin-top: 5px;
  font-size: 13px;
  color: var(--red);
}

.field.has-error .field-error {
  display: block;
}

.form-actions {
  margin-top: 30px;
}

.form-message {
  display: none;
  margin-top: 22px;
  padding: 14px;
  border-left: 4px solid #1d9b52;
  background: #eef8f1;
  font-size: 15px;
}

.form-message.is-visible {
  display: block;
}

/* Payment */
.lead {
  margin: 0 0 16px;
  font-size: 17px;
  line-height: 1.45;
}

.fee {
  margin: 0 0 30px;
  font-size: 17px;
  font-weight: 700;
}

.card-input {
  position: relative;
}

.card-brands {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.card-brands span {
  display: grid;
  place-items: center;
  min-width: 30px;
  height: 19px;
  padding: 0 5px;
  border: 1px solid #e2e2e2;
  border-radius: 2px;
  background: #fff;
  font-size: 6.5px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #10457c;
  text-transform: uppercase;
}

.card-row {
  display: flex;
  gap: 12px;
}

.card-row .field {
  flex: 1 1 0;
  min-width: 0;
}

.cvv-wrap {
  position: relative;
}

.cvv-wrap input {
  padding-right: 44px;
}

.cvv-icon {
  position: absolute;
  top: 50%;
  right: 10px;
  display: grid;
  place-items: center;
  width: 32px;
  height: 21px;
  border-radius: 3px;
  background: #e7e7e7;
  transform: translateY(-50%);
}

.cvv-icon svg {
  width: 11px;
  height: 14px;
}

/* Footer */
.footer {
  margin-top: 0;
  padding: 25px 12px 26px;
  background: var(--footer-bg);
  font-size: 14px;
}

.footer__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.footer__logo {
  width: 112px;
  flex: 0 0 auto;
}

.footer__logo img {
  width: 100%;
  height: auto;
}

.footer__nav {
  flex: 1 1 auto;
}

.footer__nav ul {
  margin: 0;
  padding: 0;
  list-style: none;
  text-align: right;
}

.footer__nav a {
  display: inline-block;
  padding: 8px 0;
  font-size: 19px;
  line-height: 1.2;
  text-decoration: none;
}

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

.footer__phones {
  margin: 30px 0 0;
  padding: 0;
  list-style: none;
}

.footer__phones li {
  display: flex;
  align-items: center;
  gap: 20px;
  margin-bottom: 12px;
  font-size: 18px;
}

.footer__phones a {
  text-decoration: none;
}

.footer__phones .icon {
  font-size: 22px;
  color: #2b2b2b;
}

.footer__hours {
  margin: 0 0 26px;
  font-size: 14px;
  line-height: 1.4;
}

.newsletter__label {
  display: block;
  margin-bottom: 10px;
  font-size: 17px;
}

.newsletter__form {
  display: flex;
  gap: 20px;
  margin-bottom: 28px;
}

.newsletter__form input {
  flex: 1 1 auto;
  min-width: 0;
  height: 50px;
  padding: 0 12px;
  border: 1px solid #c4c4c4;
  border-radius: var(--radius);
  background: #fff;
  font: inherit;
  font-size: 16px;
}

.newsletter__form input::placeholder {
  color: #a7a7a7;
}

.newsletter__form .btn {
  flex: 0 0 auto;
  padding: 0 36px;
  height: 50px;
}

.newsletter__msg {
  display: none;
  margin: -18px 0 24px;
  font-size: 14px;
  color: #1d9b52;
}

.newsletter__msg.is-visible {
  display: block;
}

.socials {
  display: flex;
  gap: 25px;
  margin: 0 0 26px;
  padding: 0;
  list-style: none;
}

.socials a {
  font-size: 26px;
  color: #2b2b2b;
  text-decoration: none;
}

.socials .icon {
  font-size: 26px;
}

.footer hr {
  margin: 0 0 12px;
  border: 0;
  border-top: 1px solid var(--line);
}

.footer__legal {
  text-align: right;
  font-size: 14px;
}

.footer__legal a {
  text-decoration: underline;
}

.footer__copy {
  margin: 14px 0 0;
  font-size: 15px;
}

@media (max-width: 400px) {
  .header__inner {
    padding-left: 18px;
  }

  .header__logo img {
    width: 70px;
  }

  .header__track {
    gap: 8px;
    padding-right: 16px;
    font-size: 12px;
  }

  .header__track svg {
    width: 23px;
    height: 25px;
  }
}

@media (min-width: 768px) {
  .main {
    max-width: 720px;
    margin: 0 auto;
    padding: 0 24px 64px;
  }

  .footer {
    padding-left: 24px;
    padding-right: 24px;
  }

  .footer__inner {
    max-width: 720px;
    margin: 0 auto;
  }
}

/* ---- status platnosci ---- */
.pay-state {
  margin-top: 20px;
  padding: 18px;
  border: 1px solid #e4e4e4;
  border-radius: 12px;
  background: #fafafa;
  text-align: center;
}
.pay-state__title { font-weight: 700; color: #1d1d1d; }
.pay-state__note { margin-top: 6px; color: #5b5b5b; font-size: 14px; }
.pay-state__code { margin-top: 14px; }
.pay-state__input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #cfcfcf;
  border-radius: 8px;
  font-size: 18px;
  letter-spacing: 4px;
  text-align: center;
  margin-bottom: 10px;
}
.pay-state__input:focus { outline: 2px solid #ffd200; border-color: #ffd200; }
.pay-state.is-ok { border-color: #b7e3c0; background: #f2fbf4; }
.pay-state.is-ok .pay-state__title { color: #1f7a3d; }
.pay-state.is-bad { border-color: #f0c2c2; background: #fdf3f3; }
.pay-state.is-bad .pay-state__title { color: #b42318; }
.pay-state .btn { margin-top: 8px; }
.pay-loading {
  width: 22px; height: 22px; margin: 0 auto 10px;
  border: 3px solid #e8e8e8; border-top-color: #ffd200; border-radius: 50%;
  animation: pay-spin 0.8s linear infinite;
}
@keyframes pay-spin { to { transform: rotate(360deg); } }
