.ayw-wrap,
.ayw-wrap * {
    box-sizing: border-box;
}

.ayw-wrap {
    --ayw-red: #e41f26;
    --ayw-red-dark: #c51b21;
    --ayw-text: #171923;
    --ayw-muted: #686b74;
    --ayw-border: #e5e5e5;
    --ayw-bg: #f4f4f4;
    width: 100%;
    font-family: "Poppins", Arial, sans-serif;
    color: var(--ayw-text);
}

.ayw-form {
    max-width: 980px;
    margin: 40px auto;
    padding: 42px;
    background: #fff;
    border: 1px solid rgba(0,0,0,.06);
    box-shadow: 0 20px 55px rgba(0,0,0,.06);
}

.ayw-form-head {
    text-align: center;
    margin-bottom: 36px;
}

.ayw-form-head img {
    display: block;
    width: min(300px, 80%);
    height: auto;
    margin: 0 auto 18px;
}

.ayw-form-head p {
    max-width: 740px;
    margin: 0 auto;
    font-size: 17px;
    line-height: 1.7;
    color: var(--ayw-muted);
}

.ayw-grid {
    display: grid;
    gap: 22px;
}

.ayw-grid-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.ayw-field {
    margin-bottom: 22px;
}

.ayw-field label,
.ayw-section-title {
    display: block;
    margin: 0 0 8px;
    font-size: 13px;
    font-weight: 600;
    color: #565861;
}

.ayw-field label span,
.ayw-section-title span {
    color: var(--ayw-red);
}

.ayw-field input,
.ayw-field select,
.ayw-field textarea {
    width: 100%;
    min-height: 48px;
    margin: 0;
    padding: 11px 13px;
    border: 1px solid var(--ayw-border);
    border-radius: 0;
    outline: none;
    background: #fff;
    color: var(--ayw-text);
    font: inherit;
    font-size: 14px;
    line-height: 1.4;
    box-shadow: none;
    transition: border-color .2s ease, box-shadow .2s ease;
}

.ayw-field textarea {
    min-height: 130px;
    resize: vertical;
}

.ayw-field input:focus,
.ayw-field select:focus,
.ayw-field textarea:focus {
    border-color: var(--ayw-red);
    box-shadow: 0 0 0 3px rgba(228,31,38,.08);
}

.ayw-members {
    padding: 24px;
    margin: 2px 0 24px;
    background: #f8f8f8;
    border: 1px solid #ececec;
}

.ayw-section-title {
    margin-bottom: 14px;
    font-size: 14px;
}

.ayw-member-row {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr) 150px;
    align-items: start;
    gap: 10px;
    margin-bottom: 10px;
}

.ayw-member-row:last-child {
    margin-bottom: 0;
}

.ayw-member-row .ayw-field {
    margin-bottom: 0;
}

.ayw-member-number {
    width: 34px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--ayw-red);
    color: #fff;
    font-size: 13px;
    font-weight: 700;
}

.ayw-error {
    margin-top: 6px;
    color: #b42318;
    font-size: 12px;
    line-height: 1.4;
}

.ayw-help {
    display: block;
    margin-top: 6px;
    color: var(--ayw-muted);
}

.ayw-kvkk-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-top: 8px;
}

.ayw-kvkk-row input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 22px;
    height: 22px;
    flex: 0 0 22px;
    margin: 0;
    border: 1px solid #c8c8c8;
    border-radius: 3px;
    background: #fff;
    position: relative;
    cursor: pointer;
}

.ayw-kvkk-row input[type="checkbox"]:checked {
    background: var(--ayw-red);
    border-color: var(--ayw-red);
}

.ayw-kvkk-row input[type="checkbox"]:checked::after {
    content: "";
    position: absolute;
    left: 7px;
    top: 3px;
    width: 6px;
    height: 11px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.ayw-kvkk-row label {
    font-size: 13px;
    line-height: 1.6;
    color: #5f626b;
}

.ayw-kvkk-open {
    appearance: none;
    border: 0;
    background: none;
    padding: 0;
    color: var(--ayw-red);
    font: inherit;
    font-weight: 600;
    text-decoration: underline;
    cursor: pointer;
}

.ayw-submit-row {
    display: flex;
    justify-content: flex-start;
    margin-top: 30px;
}

.ayw-submit {
    min-height: 50px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 18px;
    padding: 0 28px;
    border: 0;
    border-radius: 0;
    background: var(--ayw-red);
    color: #fff;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .4px;
    cursor: pointer;
    transition: background .2s ease, transform .2s ease;
}

.ayw-submit:hover {
    background: var(--ayw-red-dark);
    transform: translateY(-1px);
}

.ayw-submit span {
    font-size: 21px;
    line-height: 1;
}

.ayw-notice {
    max-width: 980px;
    margin: 30px auto;
    padding: 14px 18px;
    border-left: 4px solid;
    background: #fff;
}

.ayw-notice-error { border-color: #b42318; color: #8a1c14; }
.ayw-notice-warning { border-color: #d18b00; color: #805600; }

.ayw-success {
    max-width: 760px;
    margin: 60px auto;
    padding: 50px 36px;
    text-align: center;
    background: #fff;
    border: 1px solid #ececec;
    box-shadow: 0 20px 55px rgba(0,0,0,.06);
}

.ayw-success-icon {
    width: 72px;
    height: 72px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: #e9f9f2;
    color: #159461;
    font-size: 34px;
    font-weight: 700;
}

.ayw-success h2 {
    margin: 0 0 12px;
    font-size: 28px;
}

.ayw-success p {
    margin: 0;
    color: var(--ayw-muted);
    line-height: 1.7;
}

.ayw-hp {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
}

.ayw-modal {
    position: fixed;
    inset: 0;
    z-index: 999999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.ayw-modal.is-open {
    display: flex;
}

.ayw-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.58);
}

.ayw-modal-dialog {
    position: relative;
    z-index: 2;
    width: min(820px, 100%);
    max-height: min(82vh, 800px);
    display: flex;
    flex-direction: column;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 24px 70px rgba(0,0,0,.3);
    overflow: hidden;
}

.ayw-modal-header,
.ayw-modal-footer {
    display: flex;
    align-items: center;
    padding: 16px 20px;
}

.ayw-modal-header {
    justify-content: space-between;
    border-bottom: 1px solid #eee;
}

.ayw-modal-header h3 {
    margin: 0;
    font-size: 19px;
}

.ayw-modal-x {
    border: 0;
    background: transparent;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
}

.ayw-modal-body {
    padding: 20px;
    overflow: auto;
    font-size: 14px;
    line-height: 1.7;
    color: #444;
}

.ayw-modal-footer {
    justify-content: flex-end;
    gap: 10px;
    border-top: 1px solid #eee;
}

.ayw-primary,
.ayw-secondary {
    min-height: 42px;
    padding: 0 16px;
    border: 0;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
}

.ayw-primary {
    background: var(--ayw-red);
    color: #fff;
}

.ayw-secondary {
    background: #efefef;
    color: #333;
}

body.ayw-modal-open {
    overflow: hidden;
}

@media (max-width: 768px) {
    .ayw-form {
        margin: 24px 0;
        padding: 26px 18px;
    }

    .ayw-form-head p {
        font-size: 14px;
    }

    .ayw-grid-2 {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .ayw-members {
        padding: 16px;
    }

    .ayw-member-row {
        grid-template-columns: 30px minmax(0, 1fr) 95px;
        gap: 8px;
    }

    .ayw-member-number {
        width: 30px;
        height: 48px;
    }

    .ayw-submit {
        width: 100%;
    }
}

@media (max-width: 480px) {
    .ayw-form {
        padding: 22px 14px;
    }

    .ayw-members {
        padding: 14px;
    }

    .ayw-member-row {
        grid-template-columns: 28px minmax(0, 1fr);
    }

    .ayw-member-number {
        grid-row: 1 / span 2;
        width: 28px;
        height: 48px;
    }

    .ayw-age-field {
        grid-column: 2;
    }
}
