/**
 * Edremülk Akıllı Danışman & Sihirbaz - Ultra Premium Tasarım
 */

:root {
    --edr-primary: #0284c7;
    --edr-primary-dark: #0369a1;
    --edr-accent: #0f766e;
    --edr-success: #10b981;
    --edr-warning: #f59e0b;
    --edr-danger: #ef4444;
    --edr-text: #1e293b;
    --edr-text-muted: #64748b;
    --edr-bg-card: #ffffff;
    --edr-border: #e2e8f0;
    --edr-radius: 14px;
    --edr-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05), 0 8px 10px -6px rgba(0, 0, 0, 0.03);
    --edr-shadow-hover: 0 20px 30px -10px rgba(2, 132, 199, 0.15);
}

.edremulk-advisor-wrapper {
    max-width: 960px;
    margin: 40px auto;
    background: var(--edr-bg-card);
    border-radius: var(--edr-radius);
    box-shadow: var(--edr-shadow);
    border: 1px solid var(--edr-border);
    padding: 35px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    color: var(--edr-text);
    box-sizing: border-box;
}

.edremulk-advisor-wrapper * {
    box-sizing: border-box;
}

/* Üst Başlık & İlerleme */
.advisor-header {
    text-align: center;
    margin-bottom: 35px;
    padding-bottom: 25px;
    border-bottom: 1px solid var(--edr-border);
}

.advisor-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: #e0f2fe;
    color: var(--edr-primary-dark);
    padding: 6px 14px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 15px;
}

.pulse-icon {
    width: 8px;
    height: 8px;
    background: var(--edr-primary);
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(2, 132, 199, 0.7);
    animation: edr-pulse 1.8s infinite;
}

@keyframes edr-pulse {
    0% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(2, 132, 199, 0.7); }
    70% { transform: scale(1); box-shadow: 0 0 0 8px rgba(2, 132, 199, 0); }
    100% { transform: scale(0.95); box-shadow: 0 0 0 0 rgba(2, 132, 199, 0); }
}

.advisor-title {
    font-size: 26px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 10px 0;
    line-height: 1.3;
}

.advisor-subtitle {
    font-size: 15px;
    color: var(--edr-text-muted);
    max-width: 650px;
    margin: 0 auto 25px auto;
    line-height: 1.5;
}

.advisor-progress-container {
    width: 100%;
    height: 8px;
    background: #f1f5f9;
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 15px;
}

.advisor-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--edr-primary), var(--edr-accent));
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.advisor-steps-indicator {
    display: flex;
    justify-content: space-between;
    max-width: 600px;
    margin: 0 auto;
}

.step-dot {
    font-size: 12px;
    font-weight: 600;
    color: #94a3b8;
    transition: color 0.3s;
}

.step-dot.active {
    color: var(--edr-primary);
}

/* Soru Başlıkları */
.step-question {
    font-size: 22px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 6px 0;
    text-align: center;
}

.step-helper {
    font-size: 14px;
    color: var(--edr-text-muted);
    text-align: center;
    margin: 0 0 30px 0;
}

/* Kart Seçenekleri */
.card-options-grid {
    display: grid;
    gap: 16px;
    margin-bottom: 30px;
}

.card-options-grid.cols-2 {
    grid-template-columns: repeat(2, 1fr);
}

.card-options-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

.advisor-card-option {
    position: relative;
    cursor: pointer;
    display: block;
}

.advisor-card-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.card-option-content {
    background: #f8fafc;
    border: 2px solid var(--edr-border);
    border-radius: 12px;
    padding: 22px 18px;
    text-align: center;
    transition: all 0.25s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.advisor-card-option:hover .card-option-content {
    border-color: #cbd5e1;
    background: #ffffff;
    transform: translateY(-2px);
}

.advisor-card-option input[type="radio"]:checked + .card-option-content {
    border-color: var(--edr-primary);
    background: #f0f9ff;
    box-shadow: var(--edr-shadow-hover);
}

.option-icon {
    font-size: 32px;
    margin-bottom: 12px;
}

.card-option-content h4 {
    margin: 0 0 6px 0;
    font-size: 16px;
    font-weight: 600;
    color: #0f172a;
}

.card-option-content p {
    margin: 0;
    font-size: 13px;
    color: var(--edr-text-muted);
    line-height: 1.4;
}

.select-badge {
    margin-top: 14px;
    display: inline-block;
    padding: 4px 14px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 20px;
    background: #e2e8f0;
    color: #475569;
    transition: all 0.2s;
}

.advisor-card-option input[type="radio"]:checked + .card-option-content .select-badge {
    background: var(--edr-primary);
    color: #ffffff;
}

/* Kutu & Form Grupları */
.advisor-section-box {
    background: #ffffff;
    border: 1px solid var(--edr-border);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}

.section-title {
    font-size: 15px;
    font-weight: 700;
    color: #334155;
    margin: 0 0 15px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid #f1f5f9;
}

.adv-form-row,
.form-row {
    display: grid;
    gap: 16px !important;
    margin-bottom: 16px !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.adv-form-row[style*="display: none"],
.adv-form-row[style*="display:none"],
.form-row[style*="display: none"],
.form-row[style*="display:none"],
.adv-form-row.is-hidden,
.form-row.is-hidden,
#row-rent-extra-buyer.is-hidden,
#row-seller-rent-extra.is-hidden {
    display: none !important;
}

.adv-form-row:before,
.adv-form-row:after,
.edremulk-advisor-wrapper .form-row:before,
.edremulk-advisor-wrapper .form-row:after {
    display: none !important;
    content: none !important;
    clear: none !important;
}

.adv-form-row.cols-2,
.form-row.cols-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
}

.adv-form-row.cols-3,
.form-row.cols-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
}

.form-group {
    position: relative;
    margin-bottom: 0 !important;
}

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    margin-bottom: 8px;
    letter-spacing: 0.2px;
}

.form-control {
    width: 100%;
    height: 46px;
    padding: 10px 14px;
    border: 1.5px solid #cbd5e1;
    border-radius: 10px;
    font-size: 14px;
    color: #1e293b;
    background: #ffffff;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

select.form-control {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' 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;
    background-size: 16px;
    padding-right: 38px;
    cursor: pointer;
}

.form-control:focus {
    outline: none;
    border-color: #0284c7;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(2, 132, 199, 0.15);
}

/* Kriter Öncelik Matrisi */
.criteria-matrix-container {
    background: #f8fafc;
    border: 1px solid var(--edr-border);
    border-radius: 12px;
    overflow: hidden;
}

.criteria-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid var(--edr-border);
    background: #ffffff;
}

.criteria-row:last-child {
    border-bottom: none;
}

.criteria-info h5 {
    margin: 0 0 2px 0;
    font-size: 14px;
    font-weight: 600;
    color: #1e293b;
}

.criteria-info p {
    margin: 0;
    font-size: 12px;
    color: var(--edr-text-muted);
}

.criteria-switches {
    display: flex;
    gap: 8px;
}

.switch-opt {
    position: relative;
    cursor: pointer;
}

.switch-opt input {
    position: absolute;
    opacity: 0;
}

.switch-opt span {
    display: inline-block;
    padding: 6px 12px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 6px;
    background: #f1f5f9;
    color: #64748b;
    border: 1px solid #e2e8f0;
    transition: all 0.2s;
}

.switch-opt input:checked + span {
    background: var(--edr-primary);
    color: #ffffff;
    border-color: var(--edr-primary);
}

.switch-opt input[value="must"]:checked + span {
    background: #b91c1c;
    border-color: #b91c1c;
    color: #fff;
}

.switch-opt input[value="yes"]:checked + span {
    background: #16a34a;
    border-color: #16a34a;
    color: #fff;
}

.switch-opt input[value="no"]:checked + span {
    background: #64748b;
    border-color: #64748b;
    color: #fff;
}

.criteria-matrix-container {
    display: none;
}

.criteria-matrix-container.active {
    display: block;
}

/* Butonlar */
.step-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid var(--edr-border);
}

.advisor-btn {
    padding: 12px 26px;
    font-size: 15px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.btn-next, .btn-submit {
    background: var(--edr-primary);
    color: #ffffff;
    margin-left: auto;
}

.btn-next:hover, .btn-submit:hover {
    background: var(--edr-primary-dark);
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.3);
}

.btn-prev {
    background: #f1f5f9;
    color: #475569;
}

.btn-prev:hover {
    background: #e2e8f0;
}

/* Sonuç Ekranı */
.result-header {
    margin-bottom: 30px;
}

.success-check-icon {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: #dcfce7;
    color: var(--edr-success);
    font-size: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 15px auto;
}

.result-lead-badge {
    background: #0f172a;
    color: #38bdf8;
    padding: 5px 15px;
    border-radius: 20px;
    font-family: monospace;
    font-size: 16px;
    font-weight: 700;
    display: inline-block;
    margin-bottom: 12px;
}

.matches-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 20px;
}

.match-property-card {
    background: #ffffff;
    border: 1px solid var(--edr-border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--edr-shadow);
    display: flex;
    flex-direction: column;
}

.match-card-thumb {
    position: relative;
    height: 180px;
    background: #cbd5e1;
}

.match-card-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.match-score-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: #10b981;
    color: #ffffff;
    padding: 6px 12px;
    border-radius: 20px;
    font-weight: 700;
    font-size: 14px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.match-card-body {
    padding: 16px;
    flex: 1;
}

.match-card-body h4 {
    margin: 0 0 8px 0;
    font-size: 16px;
}

.match-card-body .prop-price {
    font-size: 18px;
    font-weight: 700;
    color: var(--edr-primary);
    margin-bottom: 10px;
}

.breakdown-list {
    list-style: none;
    padding: 0;
    margin: 10px 0;
    font-size: 12px;
}

.breakdown-list li {
    padding: 3px 0;
}

.breakdown-list li.tam { color: #15803d; }
.breakdown-list li.uyumsuz { color: #b91c1c; }
.breakdown-list li.kismi { color: #d97706; }

/* Aktif Araştırma Güvencesi Kartı */
.active-research-card {
    background: #f0fdf4;
    border: 1.5px solid #86efac;
    border-radius: 12px;
    padding: 22px;
    margin-top: 30px;
    display: flex;
    gap: 18px;
    align-items: flex-start;
}

.research-icon {
    font-size: 32px;
}

.research-text h4 {
    margin: 0 0 8px 0;
    color: #166534;
    font-size: 18px;
}

.research-text p {
    margin: 0 0 12px 0;
    color: #1e293b;
    font-size: 14px;
    line-height: 1.5;
}

.research-meta {
    display: flex;
    gap: 20px;
    font-size: 13px;
    color: #15803d;
    font-weight: 500;
}

/* Responsive */
@media (max-width: 768px) {
    .card-options-grid.cols-2,
    .card-options-grid.cols-3,
    .adv-form-row.cols-2,
    .adv-form-row.cols-3,
    .form-row.cols-2,
    .form-row.cols-3,
    .matches-grid {
        grid-template-columns: 1fr !important;
    }
    .criteria-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .edremulk-advisor-wrapper {
        padding: 20px;
    }
    .research-meta {
        flex-direction: column;
        gap: 6px;
    }
}
