.sim-wrapper {
    font-family: inherit;
    box-sizing: border-box;
    width: 100%;
    max-width: 100%;
    margin: 0 auto;
}

.sim-wrapper * {
    box-sizing: border-box;
}

.sim-container {
    background: #ffffff;
    border-radius: 16px;
    padding: 36px 42px;
    box-shadow: 0 12px 36px rgba(15, 23, 42, 0.08); /* Koyu palet temasına uygun gölge */
    border: 1px solid #e2e8f0;
}

.sim-title {
    margin-top: 0;
    margin-bottom: 8px;
    font-size: 26px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.5px;
}

.sim-subtitle {
    font-size: 15px;
    color: #64748b;
    margin-bottom: 30px;
    margin-top: 0;
}

/* Dropzone */
.sim-dropzone {
    border: 2px dashed #cbd5e1;
    border-radius: 14px;
    padding: 36px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    background-color: #f8fafc;
    position: relative;
    margin-bottom: 15px;
}

.sim-dropzone:hover, .sim-dropzone.dragover {
    border-color: #2563eb;
    background-color: #eff6ff;
}

.sim-dropzone-content p {
    margin: 16px 0 0;
    color: #334155;
    font-size: 16px;
}

.sim-preview {
    display: flex;
    flex-direction: column;
    gap: 20px;
    margin-top: 15px;
    width: 100%;
}

/* YENİ: Modern Kart Tasarımı */
.sim-preview-card {
    display: flex;
    align-items: center;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px;
    width: 100%;
    box-shadow: 0 4px 6px -1px rgba(0,0,0,0.05);
}
.sim-preview-card img {
    height: 64px;
    width: 64px;
    object-fit: cover;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    margin-right: 16px;
    border: 1px solid #f1f5f9;
}
.sim-file-info-col {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
    text-align: left;
}
.sim-file-name { font-weight: 500; color: #64748b; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; display: block;}
.sim-file-size { font-size: 13px; color: #94a3b8; font-weight: 500;}
.sim-remove-icon-btn {
    background: #fff1f2; 
    color: #e11d48; 
    border: 1px solid #ffe4e6;
    width: 36px; height: 36px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; transition: 0.2s;
    margin-left: 15px;
    flex-shrink: 0;
}
.sim-remove-icon-btn:hover { background: #ffe4e6; color: #be123c; transform: scale(1.05); }
.sim-remove-icon-btn svg {
    display: block;
    pointer-events: none;
}

/* Analysis Columns */
.sim-analysis {
    display: flex;
    gap: 20px;
    width: 100%;
}
.sim-col {
    flex: 1;
    border-radius: 16px;
    padding: 20px;
    font-size: 13.5px;
    text-align: left;
    max-height: 250px;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 4px 24px rgba(0,0,0,0.03);
}
.sim-col h4 {
    margin: 0 0 12px 0;
    font-size: 15px;
    font-weight: 700;
}
.sim-col ul {
    margin: 0; padding: 0; list-style: none;
    color: #334155;
    line-height: 1.5;
}
.sim-col ul li {
    margin-bottom: 8px;
    border-bottom: 1px solid rgba(0,0,0,0.04);
    padding-bottom: 6px;
    display: flex;
    gap: 8px;
    word-break: break-word;
}
.sim-col ul li strong { 
    flex-shrink: 0;
    width: 85px; 
    font-weight: 600; 
}

.sim-col-red { background: #fffcfc; border: 1px solid #ffe4e6; }
.sim-col-red h4 { color: #e11d48; }
.sim-col-green { background: #fcfdfd; border: 1px solid #d1fae5; }
.sim-col-green h4 { color: #059669; }

/* Grid for Inputs */
.sim-grid-layout {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 600px) {
    .sim-grid-layout { grid-template-columns: 1fr; gap: 15px; }
    .sim-analysis { flex-direction: column; gap: 15px; }
    .sim-actions { flex-direction: column; gap: 10px; }
    .sim-container { padding: 20px; }
    .sim-col-red h4, .sim-col-green h4 { font-size: 13.5px; }
    .sim-input-group input[type="text"], .sim-input-group textarea { font-size: 16px; padding: 12px; } /* 16px prevents iOS zooming */
    .sim-btn { width: 100%; justify-content: center; padding: 14px; } /* Bigger touch targets */
    .sim-title { font-size: 20px; }
}

.sim-input-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14.5px;
    font-weight: 600;
    color: #1e293b;
}

.sim-input-group {
    margin-bottom: 18px;
}

.sim-input-group input[type="text"],
.sim-input-group textarea,
.sim-tags-input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    font-size: 15px;
    color: #0f172a;
    font-family: inherit;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background: #f8fafc;
    box-sizing: border-box;
}

.sim-tags-input {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    align-items: center;
    padding: 8px 14px;
    min-height: 48px;
    cursor: text;
}

.sim-tags-input.sim-focus {
    outline: none;
    border-color: #2563eb;
    box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.1);
}

.sim-tag {
    background: #eff6ff;
    border: 1px solid #bfdbfe;
    color: #1d4ed8;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    font-weight: 500;
}

.sim-tag-remove {
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
    color: #1d4ed8;
}

.sim-tag-remove:hover {
    color: #b91c1c;
}

.sim-tags-input input[type="text"] {
    border: none;
    padding: 0;
    background: transparent;
    outline: none;
    flex: 1;
    min-width: 60px;
    box-shadow: none;
    font-size: 14.5px;
}

.sim-input-group input[type="text"]:focus,
.sim-input-group textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
    background: #ffffff;
}

.sim-input-group small {
    display: block;
    margin-top: 8px;
    font-size: 13px;
    color: #64748b;
}

/* Format Selector (Piano style) */
.sim-format-selector {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 24px;
}

.sim-format-card {
    position: relative;
    cursor: pointer;
}

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

.sim-format-content {
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 16px;
    padding: 16px 12px;
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.sim-format-card input:checked + .sim-format-content {
    background: #ffffff;
    border-color: #3b82f6;
    box-shadow: 0 10px 15px -3px rgba(59, 130, 246, 0.1), 0 4px 6px -2px rgba(59, 130, 246, 0.05);
    transform: translateY(-2px);
}

.sim-format-card input:checked + .sim-format-content .sim-format-label {
    color: #2563eb;
}

.sim-format-icon {
    font-size: 20px;
    margin-bottom: 4px;
}

.sim-format-label {
    font-size: 15px;
    font-weight: 700;
    color: #1e293b;
    display: block;
}

.sim-format-desc {
    font-size: 11px;
    color: #94a3b8;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

@media (max-width: 480px) {
    .sim-format-selector {
        grid-template-columns: 1fr;
        gap: 8px;
    }
    .sim-format-content {
        flex-direction: row;
        justify-content: flex-start;
        padding: 12px 20px;
        gap: 15px;
    }
    .sim-format-icon { margin-bottom: 0; }
    .sim-format-desc { margin-left: auto; }
}

/* Action Buttons */
.sim-actions {
    display: flex;
    gap: 16px;
    margin-top: 32px;
}

.sim-submit-btn {
    flex: 1;
    padding: 18px 24px;
    font-size: 17px;
    font-weight: 600;
    border: none;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.sim-optimize-btn {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    color: white;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.15);
}
.sim-optimize-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(15, 23, 42, 0.25);
    background: linear-gradient(135deg, #334155 0%, #1e293b 100%);
}

.sim-download-btn {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: white;
    animation: sim-slide-up 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}
.sim-download-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.3);
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
}

.sim-submit-btn:active:not(:disabled) {
    transform: translateY(2px);
}

.sim-submit-btn:disabled {
    background: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.sim-optimize-btn.sim-is-loading {
    opacity: 0.8;
    cursor: wait;
}

lottie-player {
    pointer-events: none;
}

@keyframes sim-slide-up {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.sim-spinner {
    width: 20px;
    height: 20px;
    border: 3px solid rgba(255,255,255,0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: sim-spin 1s cubic-bezier(0.4, 0, 0.2, 1) infinite;
}

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