/**
 * SEO ROI Calculator Pro v2.0 - Styles
 * Mimoza Bilişim - Modern, responsive tasarım
 */

/* ========== Reset & Base ========== */
.seoroicalc-wrapper * {
    box-sizing: border-box;
}
.seoroicalc-wrapper {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #333;
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

/* ========== Container ========== */
.seoroicalc-container {
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    padding: 40px;
    animation: seoroicalc-fadeInUp 0.6s ease-out;
}

/* ========== Header ========== */
.seoroicalc-header {
    text-align: center;
    margin-bottom: 35px;
    padding-bottom: 25px;
    border-bottom: 2px solid #f0f0f0;
}
.seoroicalc-title {
    font-size: 2.2em;
    font-weight: 700;
    margin: 0 0 8px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
.seoroicalc-subtitle {
    font-size: 1.05em;
    color: #666;
    margin: 0;
}

/* ========== Sections ========== */
.seoroicalc-section {
    margin-bottom: 30px;
    padding: 25px;
    background: #fafbfc;
    border-radius: 15px;
    border: 1px solid #e8ecf0;
}
.seoroicalc-section-title {
    font-size: 1.25em;
    font-weight: 600;
    color: #1a1a1a;
    margin: 0 0 5px 0;
}
.seoroicalc-section-title small {
    font-weight: 400;
    color: #888;
    font-size: 0.75em;
}
.seoroicalc-section-desc {
    color: #777;
    font-size: 0.9em;
    margin: 0 0 20px 0;
}

/* ========== Form Grid ========== */
.seoroicalc-form-grid {
    display: grid;
    gap: 20px;
    margin-bottom: 20px;
}
.seoroicalc-grid-4 {
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.seoroicalc-form-group {
    position: relative;
}
.seoroicalc-form-group label {
    display: flex;
    align-items: center;
    font-weight: 600;
    color: #444;
    margin-bottom: 6px;
    font-size: 0.9em;
}
.seoroicalc-label-icon {
    margin-right: 6px;
    font-size: 1.15em;
}
.seoroicalc-form-group input,
.seoroicalc-form-group select {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 0.95em;
    transition: all 0.3s ease;
    background: #fff;
}
.seoroicalc-form-group input:focus,
.seoroicalc-form-group select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102,126,234,0.1);
}
.seoroicalc-form-group input::placeholder {
    color: #bbb;
}
.seoroicalc-field-hint {
    display: block;
    font-size: 0.78em;
    color: #999;
    margin-top: 4px;
}

/* ========== Auto Info ========== */
.seoroicalc-auto-info {
    background: linear-gradient(135deg, #667eea08 0%, #764ba208 100%);
    border: 1px dashed #667eea;
    border-radius: 10px;
    padding: 15px 20px;
    margin-top: 10px;
}
.seoroicalc-info-grid {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}
.seoroicalc-info-item {
    display: flex;
    align-items: center;
    gap: 8px;
}
.seoroicalc-info-label {
    color: #666;
    font-size: 0.88em;
    font-weight: 500;
}
.seoroicalc-info-value {
    color: #667eea;
    font-weight: 700;
    font-size: 1.05em;
}

/* ========== Keywords Table ========== */
.seoroicalc-keywords-table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.seoroicalc-keywords-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9em;
}
.seoroicalc-keywords-table thead th {
    background: #667eea;
    color: #fff;
    padding: 10px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 0.88em;
    white-space: nowrap;
}
.seoroicalc-keywords-table thead th:first-child {
    border-radius: 8px 0 0 0;
}
.seoroicalc-keywords-table thead th:last-child {
    border-radius: 0 8px 0 0;
}
.seoroicalc-th-num { width: 40px; text-align: center; }
.seoroicalc-th-keyword { min-width: 160px; }
.seoroicalc-th-volume { width: 130px; }
.seoroicalc-th-rank { width: 120px; }
.seoroicalc-th-action { width: 45px; }

.seoroicalc-keyword-row td {
    padding: 8px 6px;
    border-bottom: 1px solid #eee;
    vertical-align: middle;
}
.seoroicalc-td-num {
    text-align: center;
    font-weight: 600;
    color: #667eea;
}
.seoroicalc-keyword-row input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 0.92em;
    transition: border-color 0.2s;
}
.seoroicalc-keyword-row input:focus {
    outline: none;
    border-color: #667eea;
}
.seoroicalc-input-rank {
    width: 80px !important;
    text-align: center;
}

.seoroicalc-btn-remove-row {
    background: #ff4d4d;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    font-size: 0.85em;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}
.seoroicalc-btn-remove-row:hover {
    background: #e60000;
    transform: scale(1.1);
}

/* Keywords Actions */
.seoroicalc-keywords-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: 15px;
    flex-wrap: wrap;
    gap: 10px;
}
.seoroicalc-btn-add-keyword {
    background: #fff;
    color: #667eea;
    border: 2px solid #667eea;
    padding: 8px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 0.9em;
    cursor: pointer;
    transition: all 0.2s;
}
.seoroicalc-btn-add-keyword:hover {
    background: #667eea;
    color: #fff;
}
.seoroicalc-keyword-count {
    font-size: 0.85em;
    color: #888;
}

/* ========== Button ========== */
.seoroicalc-form-actions {
    text-align: center;
    margin-top: 10px;
}
.seoroicalc-btn-calculate {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    border: none;
    padding: 16px 50px;
    font-size: 1.1em;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102,126,234,0.4);
}
.seoroicalc-btn-calculate:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(102,126,234,0.6);
}

/* ========== Loading ========== */
.seoroicalc-loading {
    text-align: center;
    padding: 40px;
}
.seoroicalc-spinner {
    width: 50px;
    height: 50px;
    margin: 0 auto 20px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: seoroicalc-spin 1s linear infinite;
}
.seoroicalc-loading p {
    color: #666;
    font-size: 1.1em;
    font-weight: 500;
}

/* ========== Results ========== */
.seoroicalc-results {
    animation: seoroicalc-fadeInUp 0.6s ease-out;
}
.seoroicalc-results-header {
    text-align: center;
    margin-bottom: 30px;
}
.seoroicalc-results-header h3 {
    font-size: 1.8em;
    color: #1a1a1a;
    margin: 0;
}

/* ========== Result Cards ========== */
.seoroicalc-results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 35px;
}
.seoroicalc-result-card {
    background: #fff;
    border-radius: 15px;
    padding: 22px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: 2px solid transparent;
    animation: seoroicalc-slideIn 0.5s ease-out both;
}
.seoroicalc-result-card:nth-child(1) { animation-delay: 0.1s; }
.seoroicalc-result-card:nth-child(2) { animation-delay: 0.2s; }
.seoroicalc-result-card:nth-child(3) { animation-delay: 0.3s; }
.seoroicalc-result-card:nth-child(4) { animation-delay: 0.4s; }
.seoroicalc-result-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}
.seoroicalc-card-primary { border-color: #667eea; background: linear-gradient(135deg, #667eea10 0%, #764ba210 100%); }
.seoroicalc-card-success { border-color: #4caf50; background: linear-gradient(135deg, #4caf5010 0%, #66bb6a10 100%); }
.seoroicalc-card-info { border-color: #2196f3; background: linear-gradient(135deg, #2196f310 0%, #42a5f510 100%); }
.seoroicalc-card-warning { border-color: #ff9800; background: linear-gradient(135deg, #ff980010 0%, #ffa72610 100%); }

.seoroicalc-card-icon {
    font-size: 2.2em;
    margin-bottom: 12px;
    text-align: center;
}
.seoroicalc-card-content h4 {
    font-size: 0.88em;
    color: #666;
    margin: 0 0 12px 0;
    text-align: center;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.seoroicalc-card-value {
    text-align: center;
    margin-bottom: 12px;
}
.seoroicalc-counter {
    font-size: 2em;
    font-weight: 700;
    color: #1a1a1a;
    display: inline-block;
}
.seoroicalc-currency {
    font-size: 1.3em;
    font-weight: 600;
    color: #666;
    margin-right: 4px;
}
.seoroicalc-unit {
    font-size: 0.82em;
    color: #888;
    display: block;
    margin-top: 3px;
}

/* Progress Bar */
.seoroicalc-card-progress {
    width: 100%;
    height: 5px;
    background: #e0e0e0;
    border-radius: 3px;
    overflow: hidden;
}
.seoroicalc-progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    border-radius: 3px;
    width: 0;
    animation: seoroicalc-progressBar 1.5s ease-out forwards;
}
.seoroicalc-card-success .seoroicalc-progress-bar { background: linear-gradient(90deg, #4caf50, #66bb6a); }
.seoroicalc-card-info .seoroicalc-progress-bar { background: linear-gradient(90deg, #2196f3, #42a5f5); }
.seoroicalc-card-warning .seoroicalc-progress-bar { background: linear-gradient(90deg, #ff9800, #ffa726); }

/* ========== Detail Table ========== */
.seoroicalc-details {
    background: #f9f9f9;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 25px;
    animation: seoroicalc-fadeIn 0.6s ease-out 0.5s both;
}
.seoroicalc-details h4 {
    font-size: 1.2em;
    color: #1a1a1a;
    margin: 0 0 18px 0;
    text-align: center;
}
.seoroicalc-detail-table-wrapper {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}
.seoroicalc-detail-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.85em;
    min-width: 800px;
}
.seoroicalc-detail-table thead th {
    background: #555;
    color: #fff;
    padding: 10px 8px;
    font-weight: 600;
    text-align: center;
    white-space: nowrap;
    font-size: 0.88em;
}
.seoroicalc-detail-table thead th:first-child {
    text-align: left;
    border-radius: 8px 0 0 0;
}
.seoroicalc-detail-table thead th:last-child {
    border-radius: 0 8px 0 0;
}
.seoroicalc-detail-table tbody td {
    padding: 10px 8px;
    text-align: center;
    border-bottom: 1px solid #eee;
}
.seoroicalc-dt-keyword {
    text-align: left !important;
    font-weight: 600;
    color: #333;
}
.seoroicalc-dt-positive {
    color: #2e7d32;
    font-weight: 700;
}
.seoroicalc-rank-badge {
    display: inline-block;
    padding: 3px 10px;
    border-radius: 12px;
    font-weight: 700;
    font-size: 0.9em;
}
.seoroicalc-rank-current {
    background: #ffcdd2;
    color: #c62828;
}
.seoroicalc-rank-target {
    background: #c8e6c9;
    color: #2e7d32;
}
.seoroicalc-detail-total td {
    background: #f0f0f0;
    font-size: 1em;
    padding: 12px 8px;
    border-top: 2px solid #ccc;
}

/* ========== Summary ========== */
.seoroicalc-summary {
    background: #f9f9f9;
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 25px;
    animation: seoroicalc-fadeIn 0.6s ease-out 0.6s both;
}
.seoroicalc-summary h4 {
    font-size: 1.2em;
    color: #1a1a1a;
    margin: 0 0 18px 0;
    text-align: center;
}
.seoroicalc-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 12px;
}
.seoroicalc-summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.04);
}
.seoroicalc-summary-label {
    font-weight: 500;
    color: #666;
    font-size: 0.9em;
}
.seoroicalc-summary-value {
    font-weight: 700;
    color: #1a1a1a;
    font-size: 1em;
}

/* ========== CTA ========== */
.seoroicalc-cta {
    text-align: center;
    padding: 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 15px;
    color: #fff;
    animation: seoroicalc-fadeIn 0.6s ease-out 0.7s both;
}
.seoroicalc-cta p {
    font-size: 1.15em;
    margin: 0 0 18px 0;
    font-weight: 500;
}
.seoroicalc-btn-reset {
    background: #fff;
    color: #667eea;
    border: none;
    padding: 12px 30px;
    font-size: 1em;
    font-weight: 600;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}
.seoroicalc-btn-reset:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0,0,0,0.3);
}

/* ========== Animations ========== */
@keyframes seoroicalc-fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
@keyframes seoroicalc-fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes seoroicalc-slideIn {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}
@keyframes seoroicalc-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
@keyframes seoroicalc-progressBar {
    from { width: 0; }
    to { width: 100%; }
}

/* ========== Responsive ========== */
@media (max-width: 768px) {
    .seoroicalc-container {
        padding: 20px;
    }
    .seoroicalc-title {
        font-size: 1.7em;
    }
    .seoroicalc-section {
        padding: 15px;
    }
    .seoroicalc-form-grid {
        grid-template-columns: 1fr;
    }
    .seoroicalc-results-grid {
        grid-template-columns: 1fr;
    }
    .seoroicalc-summary-grid {
        grid-template-columns: 1fr;
    }
    .seoroicalc-info-grid {
        flex-direction: column;
        gap: 10px;
    }
    .seoroicalc-btn-calculate {
        width: 100%;
    }
    .seoroicalc-counter {
        font-size: 1.6em;
    }
}
@media (max-width: 480px) {
    .seoroicalc-wrapper {
        padding: 0 10px;
        margin: 20px auto;
    }
    .seoroicalc-container {
        padding: 15px;
        border-radius: 15px;
    }
    .seoroicalc-title {
        font-size: 1.4em;
    }
    .seoroicalc-counter {
        font-size: 1.4em;
    }
}

/* ========== Print ========== */
@media print {
    .seoroicalc-form, .seoroicalc-cta, .seoroicalc-keywords-actions { display: none; }
    .seoroicalc-container { box-shadow: none; border: 1px solid #ddd; }
}
