/* ==========================================================================
   Freeline Brief v2 — styl zgodny z freeline.pl i brief.freeline.pl
   ========================================================================== */

:root {
  --fl-navy: #062439;
  --fl-pink: #ff52a5;
  --fl-pink-hover: #e84596;
  --fl-teal: #00d6b0;
  --fl-white: #ffffff;
  --fl-bg: #f2f2f2;
  --fl-text: #062439;
  --fl-text-body: #2b2b2b;
  --fl-text-muted: #666666;
  --fl-border: #dddddd;
  --fl-border-input: #c9c9c9;
  --fl-radius: 20px;
  --fl-radius-input: 12px;
  --fl-radius-pill: 100px;
  --fl-shadow-card: 0 0 10px rgba(0, 0, 0, 0.04);
  --fl-shadow-header: 0 0 5px rgba(0, 0, 0, 0.25);
  --fl-container: 950px;
  --fl-font: 'Poppins', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body.v2-body {
  margin: 0;
  font-family: var(--fl-font);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.6;
  color: var(--fl-text-body);
  background: var(--fl-bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }

a {
  color: var(--fl-pink);
  text-decoration: none;
}
a:hover { color: var(--fl-pink-hover); }

.v2-container {
  width: min(100% - 32px, var(--fl-container));
  margin-inline: auto;
}

/* Header — jak navbar na brief.freeline.pl */
.v2-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--fl-white);
  box-shadow: var(--fl-shadow-header);
}

.v2-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px 0;
}

.v2-logo img { display: block; height: 44px; width: auto; }

.v2-header__contact {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 14px;
  font-size: 14px;
  color: var(--fl-text-muted);
}

.v2-header__label { font-weight: 500; }

.v2-header__contact a {
  color: var(--fl-navy);
  font-weight: 600;
}
.v2-header__contact a:hover { color: var(--fl-pink); }

.v2-brief-switch {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--fl-text-muted);
}
.v2-brief-switch select {
  font-family: var(--fl-font);
  font-size: 13px;
  padding: 6px 14px;
  border: 1px solid var(--fl-border-input);
  border-radius: var(--fl-radius-input);
  background: var(--fl-white);
  color: var(--fl-text-body);
  cursor: pointer;
}
.v2-brief-switch select:focus {
  outline: none;
  border-color: var(--fl-navy);
}

/* Nagłówek strony — biały blok jak .info w starym briefie */
.v2-page-head {
  background: var(--fl-white);
  border-top: 6px solid var(--fl-teal);
  text-align: center;
  padding: 44px 0 40px;
  margin-bottom: 28px;
}

.v2-page-head__title {
  margin: 0 0 12px;
  font-size: clamp(26px, 4.5vw, 35px);
  font-weight: 600;
  line-height: 1.25;
  color: var(--fl-navy);
}

.v2-page-head__title .v2-accent { color: var(--fl-pink); }

.v2-page-head__subtitle {
  margin: 0 auto;
  max-width: 640px;
  font-size: 15px;
  color: var(--fl-text-muted);
  line-height: 1.65;
}

/* Hub */
.v2-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 24px;
  padding-bottom: 40px;
}

.v2-card {
  display: flex;
  flex-direction: column;
  background: var(--fl-white);
  border-radius: var(--fl-radius);
  overflow: hidden;
  box-shadow: var(--fl-shadow-card);
  text-decoration: none;
  color: inherit;
  transition: box-shadow 0.2s ease;
}

a.v2-card:hover {
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
  color: inherit;
}

.v2-card--disabled {
  opacity: 0.5;
  cursor: not-allowed;
  pointer-events: none;
}

.v2-card__image {
  aspect-ratio: 760 / 716;
  background: var(--fl-bg);
  overflow: hidden;
}

.v2-card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
}

.v2-card__body {
  padding: 18px 20px 22px;
  text-align: center;
}

.v2-card__title {
  margin: 0 0 8px;
  font-size: 17px;
  font-weight: 600;
  color: var(--fl-navy);
}

.v2-card__meta { margin: 0; }

.v2-badge {
  display: inline-block;
  font-size: 12px;
  font-weight: 500;
  padding: 4px 12px;
  border-radius: var(--fl-radius-pill);
}

.v2-badge--soon {
  background: var(--fl-bg);
  color: var(--fl-text-muted);
}

.v2-badge--live {
  background: var(--fl-teal);
  color: var(--fl-white);
}

/* CTA na dole */
.v2-cta {
  margin: 0 0 48px;
  background: var(--fl-navy);
  border-radius: var(--fl-radius);
  overflow: hidden;
}

.v2-cta__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 40px 44px;
}

.v2-cta__content { flex: 1; max-width: 560px; }

.v2-cta__title {
  margin: 0 0 12px;
  font-size: clamp(22px, 3.5vw, 30px);
  font-weight: 600;
  line-height: 1.3;
  color: var(--fl-white);
}

.v2-cta__accent { color: var(--fl-teal); }

.v2-cta__text {
  margin: 0 0 22px;
  font-size: 14px;
  line-height: 1.65;
  color: rgba(255, 255, 255, 0.8);
}

.v2-cta__icon {
  flex-shrink: 0;
  width: min(140px, 28%);
}

.v2-cta__icon img {
  display: block;
  width: 100%;
  max-width: 120px;
  margin-left: auto;
}

/* Formularz */
.v2-content { padding-bottom: 56px; }

.v2-form-intro {
  text-align: center;
  margin-bottom: 20px;
  font-size: 14px;
  color: var(--fl-text-muted);
}

.v2-form-intro p { margin: 0; }
.v2-form-intro strong { color: var(--fl-navy); font-weight: 600; }

.v2-form-note {
  font-size: 13px;
  color: var(--fl-text-muted);
  margin-bottom: 12px;
}

.v2-form-welcome {
  background: var(--fl-white);
  border-radius: var(--fl-radius);
  box-shadow: var(--fl-shadow-card);
  padding: 24px 28px;
  margin-bottom: 20px;
  font-size: 14px;
  line-height: 1.65;
  color: var(--fl-text);
}

.v2-form-welcome p { margin: 0 0 12px; }
.v2-form-welcome p:last-child { margin-bottom: 0; }

.v2-form-welcome ul {
  margin: 0 0 12px;
  padding-left: 20px;
}

.v2-form-welcome li { margin-bottom: 4px; }

.v2-section-lead {
  margin: -4px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--fl-text-muted);
}

/* Pasek postępu */
.v2-progress {
  position: sticky;
  top: 72px;
  z-index: 50;
  background: var(--fl-bg);
  padding: 12px 0 20px;
  margin-bottom: 8px;
}

.v2-progress__track {
  height: 4px;
  background: #ddd;
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 10px;
}

.v2-progress__fill {
  height: 100%;
  width: 25%;
  background: var(--fl-teal);
  border-radius: 4px;
  transition: width 0.25s ease;
}

.v2-progress__labels {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 11px;
  color: var(--fl-text-muted);
  text-align: center;
}

.v2-progress__labels li.is-active {
  color: var(--fl-navy);
  font-weight: 600;
}

.v2-progress__labels li.is-done {
  color: var(--fl-teal);
}

.v2-form {
  display: flex;
  flex-direction: column;
  gap: 28px;
}

/* Sekcje — jak .card w starym briefie */
.v2-section {
  background: var(--fl-white);
  border-radius: var(--fl-radius);
  overflow: hidden;
  box-shadow: var(--fl-shadow-card);
}

.v2-section__head {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 18px 24px;
  background: var(--fl-teal);
  text-align: center;
}

.v2-section__step {
  flex-shrink: 0;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  font-size: 13px;
  font-weight: 700;
  color: var(--fl-white);
}

.v2-section__title {
  margin: 0;
  font-size: clamp(17px, 3vw, 22px);
  font-weight: 600;
  color: var(--fl-white);
  line-height: 1.3;
}

.v2-section__body {
  padding: 28px 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* Pola */
.v2-field > label,
.v2-field__legend {
  display: block;
  font-size: 15px;
  font-weight: 600;
  color: var(--fl-navy);
  margin-bottom: 6px;
}

.v2-req { color: var(--fl-pink); margin-left: 2px; }

.v2-hint {
  margin: 0 0 8px;
  font-size: 13px;
  color: var(--fl-text-muted);
  line-height: 1.5;
  font-weight: 400;
}

.v2-input {
  width: 100%;
  font-family: var(--fl-font);
  font-size: 14px;
  color: var(--fl-text-body);
  background: var(--fl-white);
  border: 1px solid var(--fl-border-input);
  border-radius: var(--fl-radius-input);
  padding: 12px 16px;
  transition: border-color 0.15s ease;
}

.v2-input::placeholder { color: #999; }

.v2-input:focus {
  outline: none;
  border-color: var(--fl-navy);
}

.v2-field--has-error > label,
.v2-field--has-error .v2-field__legend {
  color: #b42318;
}

.v2-field--has-error .v2-input {
  border-color: #e5484d;
  background: #fffafa;
}

.v2-field--has-error .v2-input:focus {
  border-color: #e5484d;
  box-shadow: 0 0 0 3px rgba(229, 72, 77, 0.15);
}

.v2-field--has-error .v2-check-group .v2-check-item {
  border-color: #e8a0a3;
  background: #fff8f8;
}

.v2-field--has-error .v2-check-group .v2-check-item:hover {
  border-color: #e5484d;
}

.v2-field-error {
  margin: 8px 0 0;
  font-size: 13px;
  line-height: 1.45;
  color: #c41e24;
}

.v2-form-errors {
  background: #fff5f5;
  border: 1px solid #f5c2c4;
  border-radius: var(--fl-radius);
  padding: 16px 20px;
  margin-bottom: 20px;
}

.v2-form-errors__title {
  margin: 0 0 10px;
  font-size: 14px;
  font-weight: 600;
  color: #9b1c1f;
}

.v2-form-errors__list {
  margin: 0;
  padding-left: 18px;
  font-size: 14px;
  line-height: 1.55;
}

.v2-form-errors__list a {
  color: #c41e24;
  text-decoration: underline;
}

.v2-form-errors__list a:hover {
  color: #9b1c1f;
}

.v2-textarea {
  resize: vertical;
  min-height: 100px;
  line-height: 1.6;
}

/* Radio / checkbox */
.v2-check-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.v2-check-group--cols2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.v2-check-group--inline {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.v2-check-group--inline .v2-check-item {
  flex: 1 1 auto;
  min-width: min(100%, 140px);
}

.v2-check-group--stacked .v2-check-item {
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 12px 14px;
}

.v2-check-group--stacked .v2-check-item input[type="checkbox"] {
  margin-top: 0;
}

.v2-field-grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px 20px;
}

.v2-field-grid-2 > .v2-field {
  margin: 0;
}

.v2-check-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  margin-bottom: 0;
  font-weight: 400;
  background: var(--fl-white);
  border: 1px solid var(--fl-border);
  border-radius: var(--fl-radius-input);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease;
}

.v2-check-item:hover {
  border-color: #c5c5c5;
}

.v2-check-item:has(input:checked) {
  border-color: var(--fl-teal);
  background: #f7fffc;
}

.v2-check-item input[type="radio"],
.v2-check-item input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  display: grid;
  place-content: center;
  width: 18px;
  height: 18px;
  margin-top: 2px;
  border: 2px solid #d1d1d1;
  background: var(--fl-white);
  flex-shrink: 0;
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
}

.v2-check-item input[type="radio"] {
  border-radius: 50%;
}

.v2-check-item input[type="checkbox"] {
  border-radius: 5px;
}

.v2-check-item input[type="radio"]::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--fl-white);
  transform: scale(0);
  transition: transform 0.15s ease;
}

.v2-check-item input[type="checkbox"]::before {
  content: "";
  width: 5px;
  height: 9px;
  border: solid var(--fl-white);
  border-width: 0 2px 2px 0;
  transform: rotate(45deg) scale(0);
  margin-top: -1px;
  transition: transform 0.15s ease;
}

.v2-check-item input[type="radio"]:checked {
  border-color: var(--fl-teal);
  background: var(--fl-teal);
}

.v2-check-item input[type="radio"]:checked::before {
  transform: scale(1);
}

.v2-check-item input[type="checkbox"]:checked {
  border-color: var(--fl-teal);
  background: var(--fl-teal);
}

.v2-check-item input[type="checkbox"]:checked::before {
  transform: rotate(45deg) scale(1);
}

.v2-check-item input[type="radio"]:focus-visible,
.v2-check-item input[type="checkbox"]:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(0, 214, 176, 0.25);
}

.v2-field--has-error .v2-check-item input[type="radio"],
.v2-field--has-error .v2-check-item input[type="checkbox"] {
  border-color: #e5484d;
}

.v2-field--has-error .v2-check-item input[type="radio"]:checked,
.v2-field--has-error .v2-check-item input[type="checkbox"]:checked {
  border-color: #e5484d;
  background: #e5484d;
}

.v2-check-item span {
  font-size: 14px;
  font-weight: 600;
  color: var(--fl-text-body);
  line-height: 1.5;
}

.v2-check-item--inline { flex: 1; min-width: 0; }

.v2-yesno-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.v2-yesno-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: var(--fl-bg);
  border-radius: var(--fl-radius-input);
}

.v2-yesno-row__label {
  flex: 1 1 200px;
  font-size: 14px;
  font-weight: 500;
  color: var(--fl-navy);
  line-height: 1.5;
}

.v2-yesno-row__options {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex: 1 1 280px;
}

.v2-field--hidden { display: none; }

.v2-struktura-hint {
  margin: 8px 0;
  border-radius: var(--fl-radius-input);
  overflow: hidden;
  border: 1px solid var(--fl-border);
}

.v2-info-box {
  background: var(--fl-bg);
  border-left: 4px solid var(--fl-teal);
  border-radius: 0 var(--fl-radius-input) var(--fl-radius-input) 0;
  padding: 14px 16px;
  font-size: 13px;
  color: var(--fl-text-muted);
  line-height: 1.6;
}

.v2-info-box a { font-weight: 500; }

.v2-subblock {
  margin: 4px 0 0;
}

.v2-subblock__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 16px;
  margin-bottom: 4px;
}

.v2-subheading {
  margin: 0 0 6px;
  font-size: 16px;
  font-weight: 600;
  color: var(--fl-navy);
  line-height: 1.35;
}

.v2-subblock__head .v2-subheading {
  margin-bottom: 0;
}

.v2-feature-block {
  margin: 0;
}

.v2-feature-list {
  margin: 8px 0 0;
  padding: 0 0 0 1.15em;
  color: var(--fl-text-body);
  font-size: 14px;
  line-height: 1.55;
}

.v2-feature-list li + li {
  margin-top: 4px;
}

.v2-color-input {
  display: flex;
  align-items: center;
  gap: 10px;
}

.v2-color-input__picker {
  width: 48px;
  height: 48px;
  padding: 0;
  border: 1px solid var(--fl-border-input);
  border-radius: var(--fl-radius-input);
  background: var(--fl-white);
  cursor: pointer;
  flex-shrink: 0;
}

.v2-color-input__picker::-webkit-color-swatch-wrapper {
  padding: 4px;
}

.v2-color-input__picker::-webkit-color-swatch {
  border: none;
  border-radius: 6px;
}

.v2-color-input__hex {
  max-width: 140px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.v2-check-group--fonts {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.v2-font-option span {
  font-size: 15px;
  line-height: 1.4;
}

.v2-font-option--poppins span { font-family: "Poppins", sans-serif; }
.v2-font-option--montserrat span { font-family: "Montserrat", sans-serif; }
.v2-font-option--inter span { font-family: "Inter", sans-serif; }
.v2-font-option--raleway span { font-family: "Raleway", sans-serif; }
.v2-font-option--roboto span { font-family: "Roboto", sans-serif; }
.v2-font-option--playfair span { font-family: "Playfair Display", serif; }
.v2-font-option--merriweather span { font-family: "Merriweather", serif; }
.v2-font-option--lora span { font-family: "Lora", serif; }
.v2-font-option--source-serif span { font-family: "Source Serif 4", serif; }
.v2-font-option--open-sans span { font-family: "Open Sans", sans-serif; }
.v2-font-option--lato span { font-family: "Lato", sans-serif; }
.v2-font-option--source-sans span { font-family: "Source Sans 3", sans-serif; }
.v2-font-option--georgia span { font-family: Georgia, "Times New Roman", serif; }
.v2-font-option--proponujcie span { font-family: var(--fl-font); font-style: italic; }

.v2-btn--sm {
  font-size: 13px;
  padding: 8px 16px;
  gap: 6px;
}

.v2-btn--ghost {
  background: transparent;
  color: var(--fl-navy);
  border-color: var(--fl-border);
}

.v2-btn--ghost:hover {
  border-color: var(--fl-navy);
  background: var(--fl-bg);
}

/* Przyciski — jak freeline.pl */
.v2-submit {
  text-align: center;
  padding: 12px 0 8px;
}

.v2-submit-note {
  font-size: 13px;
  color: var(--fl-text-muted);
  margin: 0 0 20px;
  line-height: 1.6;
}

.v2-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--fl-font);
  font-size: 16px;
  font-weight: 600;
  border: 2px solid transparent;
  border-radius: var(--fl-radius-pill);
  padding: 12px 28px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
  text-decoration: none;
}

.v2-btn--primary {
  background: var(--fl-pink);
  color: var(--fl-white);
  border-color: var(--fl-pink);
  padding: 14px 48px;
  font-size: 17px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.v2-btn--primary:hover {
  background: var(--fl-white);
  color: var(--fl-pink);
  border-color: var(--fl-pink);
}

.v2-btn--cta {
  background: var(--fl-teal);
  color: var(--fl-navy);
  border-color: var(--fl-teal);
  font-size: 15px;
  text-transform: none;
  padding: 10px 22px 10px 24px;
}

.v2-btn--cta:hover {
  background: var(--fl-white);
  color: var(--fl-navy);
  border-color: var(--fl-teal);
}

.v2-btn--secondary {
  background: var(--fl-white);
  color: var(--fl-navy);
  border-color: var(--fl-border);
}

.v2-btn--secondary:hover {
  border-color: var(--fl-navy);
  color: var(--fl-navy);
}

.v2-btn__arrow {
  display: inline-flex;
  width: 24px;
  height: 24px;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  font-size: 13px;
}

.v2-btn--cta .v2-btn__arrow {
  background: var(--fl-white);
}

.v2-btn--primary:hover .v2-btn__arrow {
  background: var(--fl-pink);
  color: var(--fl-white);
}

.v2-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Podziękowanie */
.v2-thanks {
  text-align: center;
  padding: 56px 24px 72px;
  max-width: 520px;
  margin: 0 auto;
}

.v2-thanks__icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 20px;
  background: var(--fl-teal);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 700;
  color: var(--fl-white);
}

.v2-thanks h1 {
  margin: 0 0 12px;
  font-size: 28px;
  font-weight: 600;
  color: var(--fl-navy);
}

.v2-thanks p {
  margin: 0 0 28px;
  color: var(--fl-text-muted);
  line-height: 1.7;
}

.v2-thanks__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

/* Stopka */
.v2-footer {
  background: var(--fl-white);
  border-top: 1px solid var(--fl-border);
  padding: 18px 0;
}

.v2-footer__inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 13px;
  color: var(--fl-text-muted);
}

.v2-footer a { font-weight: 500; }

/* Responsive */
@media (max-width: 768px) {
  .v2-header__inner {
    flex-direction: column;
    align-items: flex-start;
    padding-block: 12px;
  }

  .v2-page-head { padding: 32px 0 28px; }

  .v2-section__body { padding: 20px 16px 24px; }

  .v2-progress { top: 0; }

  .v2-progress__labels {
    font-size: 10px;
    gap: 4px;
  }

  .v2-field-grid-2,
  .v2-check-group--cols2,
  .v2-check-group--fonts {
    grid-template-columns: 1fr;
  }

  .v2-grid { grid-template-columns: 1fr; }

  .v2-cta__inner {
    flex-direction: column;
    text-align: center;
    padding: 28px 20px;
  }

  .v2-cta__icon {
    width: 100px;
    order: -1;
  }

  .v2-cta__icon img { margin: 0 auto; }

  .v2-btn--primary {
    width: 100%;
    max-width: 320px;
  }
}
