/* ==========================================================================
   BYS Front-End Form Styles
   Designed to sit cleanly inside Divi page layouts.
   All selectors are namespaced under .bys-wrap to avoid conflicts.
   ========================================================================== */

/* ------------------------------------------------------------------
   Wrapper & Intro
   ------------------------------------------------------------------ */

.bys-wrap {
    max-width: 860px;
    margin: 0 auto;
    font-family: inherit;
    color: inherit;
}

.bys-intro {
    font-size: 1.05em;
    line-height: 1.65;
    margin-bottom: 28px;
    color: #444;
}

/* Zamok note banner */
.bys-zamok-note {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    background: #f0f6ff;
    border-left: 4px solid #0073aa;
    border-radius: 0 4px 4px 0;
    padding: 14px 18px;
    margin-bottom: 32px;
    font-size: 0.92em;
    line-height: 1.5;
    color: #2c3e50;
}

.bys-zamok-icon {
    font-size: 1.3em;
    flex-shrink: 0;
    margin-top: 1px;
}

/* ------------------------------------------------------------------
   Sections
   ------------------------------------------------------------------ */

.bys-section {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 28px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,.06);
}

.bys-section-title {
    font-size: 1.1em;
    font-weight: 700;
    margin: 0;
    padding: 16px 24px;
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    color: #1a2b3c;
    letter-spacing: 0.01em;
}

.bys-section-body {
    padding: 22px 24px;
}

.bys-section-intro {
    margin: 0 0 16px;
    font-size: 0.92em;
    color: #666;
}

/* ------------------------------------------------------------------
   Field Rows & Fields
   ------------------------------------------------------------------ */

.bys-field-row {
    margin-bottom: 18px;
}

.bys-field-row:last-child {
    margin-bottom: 0;
}

.bys-two-col {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media ( max-width: 640px ) {
    .bys-two-col {
        grid-template-columns: 1fr;
    }
}

.bys-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.bys-field label {
    font-size: 0.9em;
    font-weight: 600;
    color: #374151;
    margin: 0;
}

.bys-required {
    color: #dc2626;
    margin-left: 2px;
}

.bys-field input[type="text"],
.bys-field input[type="email"],
.bys-field input[type="tel"],
.bys-field input[type="number"],
.bys-field select,
.bys-field textarea {
    width: 100%;
    padding: 10px 13px;
    border: 1px solid #d1d5db;
    border-radius: 5px;
    font-size: 0.95em;
    color: #111;
    background: #fff;
    transition: border-color 0.15s, box-shadow 0.15s;
    box-sizing: border-box;
    font-family: inherit;
    -webkit-appearance: none;
    appearance: none;
}

.bys-field input[type="number"] {
    -moz-appearance: textfield;
}

.bys-field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b7280' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
}

.bys-field input:focus,
.bys-field select:focus,
.bys-field textarea:focus {
    outline: none;
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0,115,170,.15);
}

.bys-field input.bys-field-error,
.bys-field select.bys-field-error,
.bys-field textarea.bys-field-error {
    border-color: #dc2626;
    box-shadow: 0 0 0 3px rgba(220,38,38,.12);
}

.bys-field textarea {
    resize: vertical;
    min-height: 110px;
}

/* ------------------------------------------------------------------
   Inline radio groups
   ------------------------------------------------------------------ */

.bys-radio-inline {
    display: flex;
    flex-wrap: wrap;
    gap: 10px 20px;
    align-items: center;
    padding-top: 4px;
}

.bys-radio-inline label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.92em;
    font-weight: 400;
    cursor: pointer;
    color: #374151;
}

.bys-radio-inline input[type="radio"] {
    accent-color: #0073aa;
    width: 16px;
    height: 16px;
    cursor: pointer;
    flex-shrink: 0;
}

/* Radio list (kiosk list style) */
.bys-radio-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.bys-radio-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
}

.bys-radio-item:hover {
    border-color: #0073aa;
    background: #f0f6ff;
}

.bys-radio-item input[type="radio"] {
    margin-top: 2px;
    accent-color: #0073aa;
    flex-shrink: 0;
}

.bys-radio-label {
    font-size: 0.95em;
    color: #1a2b3c;
}

/* ------------------------------------------------------------------
   Kiosk Cards
   ------------------------------------------------------------------ */

.bys-kiosk-cards {
    display: grid;
    grid-template-columns: repeat( auto-fill, minmax( 220px, 1fr ) );
    gap: 16px;
}

@media ( max-width: 500px ) {
    .bys-kiosk-cards {
        grid-template-columns: 1fr;
    }
}

.bys-kiosk-card {
    display: block;
    cursor: pointer;
}

.bys-kiosk-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.bys-kiosk-card-inner {
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    transition: border-color 0.15s, box-shadow 0.15s;
    background: #fff;
    height: 100%;
    display: flex;
    flex-direction: column;
    position: relative;
}

.bys-kiosk-card:hover .bys-kiosk-card-inner {
    border-color: #0073aa;
    box-shadow: 0 2px 8px rgba(0,115,170,.18);
}

.bys-kiosk-card input[type="radio"]:checked + .bys-kiosk-card-inner {
    border-color: #0073aa;
    box-shadow: 0 0 0 3px rgba(0,115,170,.2);
}

.bys-kiosk-card-check-indicator {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 2px solid #d1d5db;
    background: #fff;
    transition: all 0.15s;
    z-index: 1;
}

.bys-kiosk-card input[type="radio"]:checked + .bys-kiosk-card-inner .bys-kiosk-card-check-indicator {
    background: #0073aa;
    border-color: #0073aa;
}

.bys-kiosk-card input[type="radio"]:checked + .bys-kiosk-card-inner .bys-kiosk-card-check-indicator::after {
    content: '';
    display: block;
    width: 6px;
    height: 10px;
    border: 2px solid #fff;
    border-top: none;
    border-left: none;
    transform: rotate(45deg) translate(2px, -1px);
}

.bys-kiosk-card-image {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    min-height: 160px;
}

.bys-kiosk-card-image img {
    max-width: 100%;
    max-height: 140px;
    object-fit: contain;
    display: block;
}

.bys-kiosk-card-body {
    padding: 14px 16px;
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.bys-kiosk-card-body h4 {
    margin: 0;
    font-size: 1em;
    font-weight: 700;
    color: #1a2b3c;
    line-height: 1.3;
    padding-right: 28px; /* clear the check indicator */
}

.bys-kiosk-card-body p {
    margin: 0;
    font-size: 0.86em;
    color: #555;
    line-height: 1.45;
}

.bys-kiosk-price {
    font-size: 0.88em;
    font-weight: 700;
    color: #0073aa;
}

.bys-kiosk-link {
    font-size: 0.82em;
    color: #0073aa;
    text-decoration: none;
    margin-top: auto;
    align-self: flex-start;
}

.bys-kiosk-link:hover {
    text-decoration: underline;
}

/* ------------------------------------------------------------------
   Checkbox grid
   ------------------------------------------------------------------ */

.bys-checkbox-grid {
    display: grid;
    grid-template-columns: repeat( auto-fill, minmax( 220px, 1fr ) );
    gap: 10px;
}

@media ( max-width: 480px ) {
    .bys-checkbox-grid {
        grid-template-columns: 1fr;
    }
}

.bys-checkbox-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 10px 14px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
    font-size: 0.9em;
    color: #374151;
    line-height: 1.4;
    user-select: none;
}

.bys-checkbox-item:hover {
    border-color: #0073aa;
    background: #f0f6ff;
}

.bys-checkbox-item input[type="checkbox"] {
    margin-top: 2px;
    accent-color: #0073aa;
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    cursor: pointer;
}

.bys-checkbox-item:has(input:checked) {
    border-color: #0073aa;
    background: #ebf4fa;
}

/* ------------------------------------------------------------------
   Pricing block
   ------------------------------------------------------------------ */

.bys-pricing-block {
    background: linear-gradient( 135deg, #0073aa 0%, #005177 100% );
    border-radius: 8px;
    padding: 24px 28px;
    margin-bottom: 28px;
    color: #fff;
}

.bys-pricing-inner {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.bys-pricing-label {
    font-size: 0.82em;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    opacity: 0.8;
}

.bys-pricing-value {
    font-size: 1.9em;
    font-weight: 800;
    line-height: 1.2;
}

.bys-pricing-note {
    font-size: 0.83em;
    opacity: 0.75;
    margin-top: 4px;
}

/* ------------------------------------------------------------------
   Errors
   ------------------------------------------------------------------ */

.bys-errors {
    background: #fef2f2;
    border: 1px solid #fca5a5;
    border-radius: 6px;
    padding: 12px 16px;
    margin-bottom: 16px;
    font-size: 0.9em;
    color: #991b1b;
    display: none;
}

.bys-errors.bys-errors-visible {
    display: block;
}

.bys-errors ul {
    margin: 4px 0 0 16px;
    padding: 0;
}

/* ------------------------------------------------------------------
   Submit row
   ------------------------------------------------------------------ */

.bys-submit-row {
    margin-top: 10px;
}

.bys-submit-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: #0073aa;
    color: #fff;
    border: none;
    border-radius: 6px;
    padding: 14px 36px;
    font-size: 1em;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.15s, transform 0.1s;
    letter-spacing: 0.01em;
    line-height: 1;
    font-family: inherit;
}

.bys-submit-btn:hover {
    background: #005d8c;
}

.bys-submit-btn:active {
    transform: scale(0.98);
}

.bys-submit-btn:disabled {
    background: #9ca3af;
    cursor: not-allowed;
    transform: none;
}

/* Spinner */
.bys-submit-spinner {
    display: none;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255,255,255,.4);
    border-top-color: #fff;
    border-radius: 50%;
    animation: bys-spin 0.7s linear infinite;
    flex-shrink: 0;
}

.bys-submitting .bys-submit-spinner {
    display: inline-block;
}

@keyframes bys-spin {
    to { transform: rotate(360deg); }
}

.bys-privacy-note {
    margin: 12px 0 0;
    font-size: 0.8em;
    color: #9ca3af;
}

/* ------------------------------------------------------------------
   Success message
   ------------------------------------------------------------------ */

.bys-success-msg {
    text-align: center;
    padding: 48px 24px;
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 8px;
}

.bys-success-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    background: #22c55e;
    color: #fff;
    border-radius: 50%;
    font-size: 1.6em;
    margin-bottom: 16px;
}

.bys-success-msg h3 {
    margin: 0 0 8px;
    font-size: 1.4em;
    color: #15803d;
}

.bys-success-msg p {
    color: #555;
    margin: 0;
}

/* ==========================================================================
   BYS Thank-You Page Styles
   ========================================================================== */

.bys-ty-wrap {
    max-width: 780px;
    margin: 0 auto;
    font-family: inherit;
    color: inherit;
}

/* Hero */
.bys-ty-hero {
    text-align: center;
    padding: 40px 24px 36px;
}

.bys-ty-check {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
}

.bys-ty-check svg {
    width: 100%;
    height: 100%;
}

.bys-ty-headline {
    font-size: 1.8em;
    font-weight: 800;
    margin: 0 0 12px;
    color: #1a2b3c;
}

.bys-ty-subline {
    font-size: 1em;
    color: #555;
    line-height: 1.65;
    max-width: 560px;
    margin: 0 auto;
}

/* Card */
.bys-ty-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,.07);
    margin-bottom: 32px;
}

.bys-ty-card-header {
    background: linear-gradient(135deg, #0073aa 0%, #005177 100%);
    padding: 24px 28px;
    color: #fff;
}

.bys-ty-system-label {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .09em;
    opacity: .75;
    display: block;
    margin-bottom: 6px;
}

.bys-ty-system-name {
    margin: 0 0 8px;
    font-size: 1.5em;
    font-weight: 800;
    line-height: 1.2;
    color: #fff;
}

.bys-ty-price-badge {
    display: inline-block;
    background: rgba(255,255,255,.18);
    border: 1px solid rgba(255,255,255,.35);
    border-radius: 20px;
    padding: 4px 14px;
    font-size: .9em;
    font-weight: 700;
    color: #fff;
    margin-right: 8px;
}

.bys-ty-price-note {
    font-size: .78em;
    opacity: .7;
    display: block;
    margin-top: 6px;
}

/* Sections inside card */
.bys-ty-section {
    padding: 18px 28px;
    border-bottom: 1px solid #f0f4f8;
}

.bys-ty-section:last-child {
    border-bottom: none;
}

.bys-ty-section-title {
    margin: 0 0 12px;
    font-size: .8em;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .07em;
    color: #6b7280;
}

/* Key/value definition list */
.bys-ty-dl {
    margin: 0;
    display: grid;
    grid-template-columns: 160px 1fr;
    gap: 6px 16px;
}

.bys-ty-dl dt {
    font-size: .88em;
    color: #6b7280;
    font-weight: 600;
    padding: 3px 0;
}

.bys-ty-dl dd {
    margin: 0;
    font-size: .92em;
    color: #1a2b3c;
    padding: 3px 0;
}

@media (max-width: 500px) {
    .bys-ty-dl {
        grid-template-columns: 1fr;
        gap: 2px;
    }
    .bys-ty-dl dt {
        margin-top: 8px;
    }
}

/* Kiosk row */
.bys-ty-kiosk-row {
    display: flex;
    gap: 18px;
    align-items: flex-start;
}

.bys-ty-kiosk-thumb {
    width: 110px;
    height: 80px;
    object-fit: contain;
    border-radius: 4px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    flex-shrink: 0;
}

.bys-ty-kiosk-info strong {
    display: block;
    font-size: 1em;
    color: #1a2b3c;
    margin-bottom: 4px;
}

.bys-ty-kiosk-info p {
    margin: 0 0 8px;
    font-size: .88em;
    color: #555;
    line-height: 1.45;
}

.bys-ty-learn-more {
    font-size: .85em;
    color: #0073aa;
    text-decoration: none;
}

.bys-ty-learn-more:hover {
    text-decoration: underline;
}

/* Tag list (hardware, software, content) */
.bys-ty-tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 7px;
}

.bys-ty-tag {
    background: #f0f6ff;
    border: 1px solid #c7e0f4;
    color: #0073aa;
    border-radius: 20px;
    padding: 4px 13px;
    font-size: .83em;
    font-weight: 600;
}

.bys-ty-sw-source {
    margin: 0 0 10px;
    font-size: .9em;
    color: #374151;
    font-weight: 600;
}

/* Notes */
.bys-ty-notes {
    margin: 0;
    font-size: .92em;
    color: #374151;
    line-height: 1.6;
    background: #f8fafc;
    padding: 12px 16px;
    border-radius: 5px;
    border-left: 3px solid #0073aa;
}

/* Zamok note row */
.bys-ty-zamok {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    background: #f0f6ff;
    font-size: .9em;
    line-height: 1.55;
    color: #1a2b3c;
}

.bys-ty-zamok-icon {
    font-size: 1.3em;
    flex-shrink: 0;
    margin-top: 1px;
}

/* Next Steps */
.bys-ty-next {
    padding: 8px 0 40px;
}

.bys-ty-next h3 {
    font-size: 1.15em;
    font-weight: 700;
    color: #1a2b3c;
    margin: 0 0 20px;
}

.bys-ty-steps {
    list-style: none;
    margin: 0 0 30px;
    padding: 0;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.bys-ty-steps li {
    display: flex;
    align-items: flex-start;
    gap: 16px;
}

.bys-ty-step-num {
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    background: #0073aa;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    font-size: .9em;
    margin-top: 2px;
}

.bys-ty-steps li > div strong {
    display: block;
    font-size: .97em;
    color: #1a2b3c;
    margin-bottom: 3px;
}

.bys-ty-steps li > div p {
    margin: 0;
    font-size: .88em;
    color: #555;
    line-height: 1.5;
}

/* CTA row */
.bys-ty-cta-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 14px;
}

.bys-ty-cta-btn {
    display: inline-block;
    background: #0073aa;
    color: #fff;
    text-decoration: none;
    padding: 13px 30px;
    border-radius: 6px;
    font-weight: 700;
    font-size: .97em;
    transition: background .15s;
}

.bys-ty-cta-btn:hover {
    background: #005d8c;
    color: #fff;
}

.bys-ty-cta-secondary {
    font-size: .9em;
    color: #0073aa;
    text-decoration: none;
}

.bys-ty-cta-secondary:hover {
    text-decoration: underline;
}
