/* ===========================
   YDP Üyelik Formu - Stiller
   =========================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* CSS Variables */
:root {
    --ydp-primary: #1f2950;
    --ydp-primary-light: #2d3a6e;
    --ydp-primary-dark: #151d3a;
    --ydp-accent: #6c63ff;
    --ydp-accent-hover: #5a52e0;
    --ydp-success: #10b981;
    --ydp-error: #ef4444;
    --ydp-warning: #f59e0b;
    --ydp-text: #1e293b;
    --ydp-text-light: #64748b;
    --ydp-bg: #f8fafc;
    --ydp-white: #ffffff;
    --ydp-border: #e2e8f0;
    --ydp-border-focus: #6c63ff;
    --ydp-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --ydp-shadow-lg: 0 20px 60px -12px rgba(31, 41, 80, 0.25);
    --ydp-radius: 12px;
    --ydp-radius-sm: 8px;
    --ydp-transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Wrapper */
.ydp-form-wrapper {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    max-width: 720px;
    margin: 0 auto;
    padding: 20px;
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
}

.ydp-form-wrapper *,
.ydp-form-wrapper *::before,
.ydp-form-wrapper *::after {
    box-sizing: border-box;
}

/* Card */
.ydp-form-card {
    background: var(--ydp-white);
    border-radius: var(--ydp-radius);
    box-shadow: var(--ydp-shadow-lg);
    padding: 40px;
    position: relative;
    overflow: hidden;
}

.ydp-form-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--ydp-primary), var(--ydp-accent));
}

/* Header */
.ydp-form-header {
    text-align: center;
    margin-bottom: 36px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--ydp-border);
}

.ydp-form-title {
    font-size: 28px;
    font-weight: 700;
    color: var(--ydp-primary);
    margin: 0 0 8px 0;
    letter-spacing: -0.5px;
}

.ydp-form-subtitle {
    font-size: 15px;
    color: var(--ydp-text-light);
    margin: 0;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Form Rows */
.ydp-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.ydp-form-row-full {
    grid-template-columns: 1fr;
}

/* Form Group */
.ydp-form-group {
    position: relative;
}

/* Labels */
.ydp-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--ydp-text);
    margin-bottom: 6px;
    transition: var(--ydp-transition);
}

.ydp-label small {
    font-weight: 400;
    color: var(--ydp-text-light);
    font-size: 12px;
}

.ydp-required {
    color: var(--ydp-error);
    font-weight: 700;
}

/* Inputs & Selects */
.ydp-input,
.ydp-select {
    width: 100%;
    padding: 14px 16px;
    min-height: 50px;
    font-size: 15px;
    font-family: inherit;
    color: var(--ydp-text);
    background: var(--ydp-bg);
    border: 2px solid var(--ydp-border);
    border-radius: var(--ydp-radius-sm);
    outline: none;
    transition: var(--ydp-transition);
    -webkit-appearance: none;
    appearance: none;
    line-height: 1.4;
}

.ydp-input::placeholder {
    color: var(--ydp-text-light);
    opacity: 0.7;
}

.ydp-input:hover,
.ydp-select:hover {
    border-color: #cbd5e1;
}

.ydp-input:focus,
.ydp-select:focus {
    border-color: var(--ydp-border-focus);
    background: var(--ydp-white);
    box-shadow: 0 0 0 4px rgba(108, 99, 255, 0.1);
}

.ydp-input.ydp-field-invalid,
.ydp-select.ydp-field-invalid {
    border-color: var(--ydp-error);
    background: #fef2f2;
}

.ydp-input.ydp-field-invalid:focus,
.ydp-select.ydp-field-invalid:focus {
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1);
}

/* Select arrow */
.ydp-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
    cursor: pointer;
}

.ydp-select:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Field Error */
.ydp-field-error {
    display: block;
    font-size: 12px;
    color: var(--ydp-error);
    margin-top: 4px;
    min-height: 0;
    transition: var(--ydp-transition);
    font-weight: 500;
}

/* KVKK Link */
.ydp-kvkk-link {
    margin: 24px 0 16px;
    text-align: center;
}

.ydp-kvkk-link a {
    color: var(--ydp-accent);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: var(--ydp-transition);
    border-bottom: 1px dashed var(--ydp-accent);
    padding-bottom: 2px;
}

.ydp-kvkk-link a:hover {
    color: var(--ydp-accent-hover);
    border-bottom-style: solid;
}

/* Checkboxes */
.ydp-checkboxes {
    margin: 8px 0 28px;
}

.ydp-checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 16px;
    cursor: pointer;
    padding: 14px 16px;
    border-radius: var(--ydp-radius-sm);
    background: var(--ydp-bg);
    border: 2px solid transparent;
    transition: var(--ydp-transition);
}

.ydp-checkbox-label:hover {
    border-color: var(--ydp-border);
    background: #f1f5f9;
}

.ydp-checkbox-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.ydp-checkmark {
    flex-shrink: 0;
    width: 22px;
    height: 22px;
    border: 2px solid var(--ydp-border);
    border-radius: 6px;
    background: var(--ydp-white);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: var(--ydp-transition);
    margin-top: 1px;
    position: relative;
}

.ydp-checkmark::after {
    content: '';
    display: none;
    width: 6px;
    height: 11px;
    border: solid var(--ydp-white);
    border-width: 0 2.5px 2.5px 0;
    transform: rotate(45deg);
    margin-top: -2px;
}

.ydp-checkbox-label input:checked + .ydp-checkmark {
    background: var(--ydp-accent);
    border-color: var(--ydp-accent);
}

.ydp-checkbox-label input:checked + .ydp-checkmark::after {
    display: block;
}

.ydp-checkbox-text {
    font-size: 14px;
    color: var(--ydp-text);
    line-height: 1.5;
    flex: 1;
}

/* Submit Button */
.ydp-form-submit {
    text-align: center;
}

.ydp-btn-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 16px 32px;
    font-size: 16px;
    font-weight: 700;
    font-family: inherit;
    color: var(--ydp-white);
    background: linear-gradient(135deg, var(--ydp-primary), var(--ydp-accent));
    border: none;
    border-radius: var(--ydp-radius-sm);
    cursor: pointer;
    transition: var(--ydp-transition);
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    overflow: hidden;
}

.ydp-btn-submit::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transition: left 0.5s;
}

.ydp-btn-submit:hover::before {
    left: 100%;
}

.ydp-btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(108, 99, 255, 0.35);
}

.ydp-btn-submit:active {
    transform: translateY(0);
}

.ydp-btn-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

/* Spinner */
.ydp-spinner {
    animation: ydp-spin 1s linear infinite;
}

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

/* Alert Messages */
.ydp-alert {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 16px 20px;
    border-radius: var(--ydp-radius-sm);
    margin-bottom: 24px;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
    animation: ydp-slideDown 0.4s ease-out;
}

.ydp-alert svg {
    flex-shrink: 0;
    margin-top: 1px;
}

.ydp-alert-success {
    background: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.ydp-alert-error {
    background: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

@keyframes ydp-slideDown {
    from { opacity: 0; transform: translateY(-12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Modal */
.ydp-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 999999;
    padding: 20px;
    animation: ydp-fadeIn 0.3s ease;
}

.ydp-modal {
    background: var(--ydp-white);
    border-radius: var(--ydp-radius);
    max-width: 640px;
    width: 100%;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 25px 80px rgba(0, 0, 0, 0.3);
    animation: ydp-scaleIn 0.3s ease;
}

.ydp-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid var(--ydp-border);
}

.ydp-modal-header h3 {
    margin: 0;
    font-size: 18px;
    color: var(--ydp-primary);
    font-weight: 700;
}

.ydp-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--ydp-text-light);
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: var(--ydp-transition);
}

.ydp-modal-close:hover {
    color: var(--ydp-error);
}

.ydp-modal-body {
    padding: 24px;
    overflow-y: auto;
    font-size: 14px;
    line-height: 1.7;
    color: var(--ydp-text);
}

.ydp-modal-body h4 {
    font-size: 16px;
    margin: 0 0 16px;
    color: var(--ydp-primary);
}

.ydp-modal-body h5 {
    font-size: 15px;
    margin: 20px 0 8px;
    color: var(--ydp-primary-light);
}

.ydp-modal-body p {
    margin: 0 0 12px;
}

.ydp-modal-body ul {
    margin: 0 0 12px;
    padding-left: 20px;
}

.ydp-modal-body li {
    margin-bottom: 6px;
}

.ydp-modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--ydp-border);
    text-align: right;
}

.ydp-modal-footer .ydp-btn-submit {
    width: auto;
    padding: 12px 28px;
    font-size: 14px;
}

@keyframes ydp-fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes ydp-scaleIn {
    from { opacity: 0; transform: scale(0.95); }
    to { opacity: 1; transform: scale(1); }
}

/* ===============
   Responsive
   =============== */
@media (max-width: 640px) {
    .ydp-form-wrapper {
        padding: 12px;
    }

    .ydp-form-card {
        padding: 24px 20px;
    }

    .ydp-form-title {
        font-size: 22px;
    }

    .ydp-form-subtitle {
        font-size: 12px;
    }

    .ydp-form-row {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    .ydp-input,
    .ydp-select {
        padding: 11px 14px;
        font-size: 14px;
    }

    .ydp-btn-submit {
        padding: 14px 24px;
        font-size: 15px;
    }

    .ydp-checkbox-label {
        padding: 12px;
    }

    .ydp-checkbox-text {
        font-size: 13px;
    }

    .ydp-modal {
        max-height: 90vh;
    }
}
