/* Reset ve Temel Stiller */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
header {
    text-align: center;
    margin-bottom: 40px;
    color: white;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

header h1 i {
    margin-right: 15px;
    color: #fff;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
}

/* Bölüm Stilleri */
section {
    background: white;
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
}

section:hover {
    transform: translateY(-2px);
}

section h2 {
    color: #4a5568;
    margin-bottom: 25px;
    font-size: 1.5rem;
    border-bottom: 3px solid #667eea;
    padding-bottom: 10px;
}

section h2 i {
    margin-right: 10px;
    color: #667eea;
}

/* Form Stilleri */
.phone-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-weight: 600;
    margin-bottom: 5px;
    color: #4a5568;
    font-size: 0.95rem;
}

.optional-label {
    font-weight: 400;
    color: #718096;
    font-size: 0.85rem;
}

.form-group input,
.form-group select,
.form-group textarea {
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background: #f8fafc;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group input:invalid {
    border-color: #e53e3e;
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* IMEI Input Grup */
.imei-input-group {
    display: flex;
    gap: 8px;
    align-items: stretch;
}

.imei-input-group input {
    flex: 1;
}

.btn-paste,
.btn-clear {
    padding: 8px 12px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    background: #f8fafc;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
}

.btn-paste {
    color: #4299e1;
    border-color: #bee3f8;
}

.btn-paste:hover {
    background: #ebf8ff;
    border-color: #4299e1;
    color: #2b6cb0;
}

.btn-clear {
    color: #e53e3e;
    border-color: #fed7d7;
}

.btn-clear:hover {
    background: #fed7d7;
    border-color: #e53e3e;
    color: #c53030;
}

.imei-help {
    display: block;
    margin-top: 5px;
    color: #718096;
    font-size: 0.85rem;
    font-style: italic;
}

/* Otomatik Doldurma Kontrolleri */
.auto-fill-controls {
    display: flex !important;
    gap: 10px !important;
    margin-bottom: 25px !important;
    flex-wrap: wrap !important;
    justify-content: center !important;
    padding: 20px !important;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%) !important;
    border-radius: 12px !important;
    border: 2px solid #cbd5e0 !important;
    visibility: visible !important;
    opacity: 1 !important;
    width: 100% !important;
    box-sizing: border-box !important;
}

.btn-auto-fill,
.btn-camera {
    padding: 12px 20px !important;
    border: none !important;
    border-radius: 8px !important;
    font-size: 0.95rem !important;
    font-weight: 600 !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    min-width: 160px !important;
    justify-content: center !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.btn-auto-fill {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 50%, #f093fb 100%) !important;
    color: white !important;
    border: 3px solid transparent !important;
    outline: none !important;
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4) !important;
    position: relative !important;
    overflow: hidden !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.5px !important;
    padding: 15px 25px !important;
    border-radius: 12px !important;
    font-size: 1rem !important;
}

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

.btn-auto-fill:hover::before {
    left: 100% !important;
}

.btn-auto-fill:hover {
    transform: translateY(-3px) scale(1.02) !important;
    box-shadow: 0 12px 35px rgba(102, 126, 234, 0.6) !important;
    background: linear-gradient(135deg, #5a67d8 0%, #6b46c1 50%, #ed64a6 100%) !important;
    border-color: rgba(255,255,255,0.3) !important;
}

.btn-auto-fill:active {
    transform: translateY(-1px) scale(0.98) !important;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.5) !important;
}

.btn-auto-fill i {
    font-size: 1.2rem !important;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.3)) !important;
}

.btn-camera {
    background: linear-gradient(135deg, #48bb78, #38a169) !important;
    color: white !important;
}

.btn-camera:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(72, 187, 120, 0.3) !important;
}


.btn-decode {
    background: linear-gradient(135deg, #ed8936, #dd6b20);
    color: white;
    border: none;
    padding: 8px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.btn-decode:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 15px rgba(237, 137, 54, 0.3);
}

.input-group {
    display: flex;
    gap: 8px;
    align-items: center;
}

.input-group input {
    flex: 1;
}


/* Görsel Yükleme Sistemi */
.image-upload-system {
    margin-bottom: 30px;
    padding: 25px;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 15px;
    border: 2px solid #cbd5e0;
}

.image-upload-system h3 {
    color: #4a5568;
    margin-bottom: 15px;
    font-size: 1.3rem;
    text-align: center;
}

.image-upload-system h3 i {
    margin-right: 10px;
    color: #667eea;
}

.upload-description {
    text-align: center;
    color: #718096;
    margin-bottom: 25px;
    font-size: 1rem;
    line-height: 1.6;
}

.upload-description strong {
    color: #4a5568;
    font-weight: 600;
}

.image-upload-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.image-upload-item {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.upload-area {
    border: 3px dashed #cbd5e0;
    border-radius: 12px;
    padding: 30px 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    min-height: 140px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.upload-area:hover {
    border-color: #667eea;
    background: #f0f4ff;
    transform: translateY(-2px);
}

.upload-area.dragover {
    border-color: #667eea;
    background: #f0f4ff;
    border-style: solid;
}

.upload-area.processing {
    border-color: #f6ad55;
    background: #fffaf0;
    pointer-events: none;
}

.upload-area.success {
    border-color: #48bb78;
    background: #f0fff4;
}

.upload-area.error {
    border-color: #e53e3e;
    background: #fffaf0;
}

.upload-area i {
    font-size: 2.5rem;
    color: #a0aec0;
    margin-bottom: 10px;
}

.upload-area.processing i {
    color: #f6ad55;
    animation: spin 1s linear infinite;
}

.upload-area.success i {
    color: #48bb78;
}

.upload-area.error i {
    color: #e53e3e;
}

.upload-area p {
    font-size: 1.1rem;
    font-weight: 600;
    color: #4a5568;
    margin: 0;
}

.upload-area small {
    font-size: 0.9rem;
    color: #718096;
    margin: 0;
}

.image-preview {
    border-radius: 8px;
    overflow: hidden;
    border: 2px solid #e2e8f0;
    max-height: 200px;
}

.image-preview img {
    width: 100%;
    height: auto;
    display: block;
}

.upload-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 20px;
}

/* Kullanım Kılavuzu */
.usage-guide {
    margin-top: 20px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
}

.usage-guide h4 {
    color: #4a5568;
    margin-bottom: 20px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.usage-guide h4 i {
    color: #4299e1;
}

.guide-steps {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.guide-step {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    padding: 15px;
    background: white;
    border-radius: 8px;
    border-left: 4px solid #4299e1;
    transition: all 0.3s ease;
}

.guide-step:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(66, 153, 225, 0.15);
}

.step-number {
    background: linear-gradient(135deg, #4299e1, #3182ce);
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 0.9rem;
    flex-shrink: 0;
}

.step-content {
    flex: 1;
}

.step-content strong {
    display: block;
    color: #2d3748;
    margin-bottom: 5px;
    font-size: 1rem;
}

.step-content p {
    color: #718096;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.4;
}

/* OCR Scanner Stilleri */
.ocr-modal-content {
    max-width: 700px;
}


/* OCR Results */
.ocr-results {
    margin: 20px 0;
    padding: 20px;
    background: #f8fafc;
    border-radius: 8px;
    border: 2px solid #e2e8f0;
}

.ocr-results h4 {
    color: #4a5568;
    margin-bottom: 15px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ocr-text-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.ocr-text-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px;
    background: white;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

.ocr-text-content {
    flex: 1;
    margin-right: 10px;
}

.ocr-text-value {
    font-family: 'Courier New', monospace;
    font-weight: bold;
    color: #2d3748;
    font-size: 0.95rem;
}

.ocr-text-type {
    font-size: 0.8rem;
    color: #718096;
    margin-top: 2px;
}

.ocr-use-btn {
    background: #9f7aea;
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.85rem;
    transition: all 0.3s ease;
}

.ocr-use-btn:hover {
    background: #805ad5;
    transform: translateY(-1px);
}

/* Tümünü Kullan Butonu */
.ocr-use-all {
    margin-bottom: 20px;
    text-align: center;
    padding: 15px;
    background: linear-gradient(135deg, #f7fafc, #edf2f7);
    border-radius: 12px;
    border: 2px dashed #cbd5e0;
}

.ocr-use-all-btn {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.ocr-use-all-btn:hover {
    background: linear-gradient(135deg, #5a67d8, #6b46c1);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.4);
}

.ocr-use-all-btn:active {
    transform: translateY(0);
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

/* OCR Category Styles */
.ocr-category {
    margin-bottom: 25px;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    background: #ffffff;
    overflow: hidden;
}

.ocr-category-title {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    margin: 0;
    padding: 15px 20px;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.ocr-category-title i {
    font-size: 18px;
}

.ocr-category-items {
    padding: 15px;
}

.ocr-text-item.categorized {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 12px;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s ease;
}

.ocr-text-item.categorized:hover {
    background: #f1f5f9;
    border-color: #cbd5e1;
    transform: translateY(-1px);
}

.ocr-text-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.ocr-text-header i {
    color: #6366f1;
    font-size: 16px;
    width: 20px;
}

.ocr-text-description {
    font-weight: 600;
    color: #374151;
    font-size: 14px;
}

.ocr-text-item.categorized .ocr-text-value {
    font-family: 'Courier New', monospace;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
    word-break: break-all;
}

.ocr-text-source {
    font-size: 12px;
    color: #6b7280;
    font-style: italic;
}

.ocr-text-item.categorized .ocr-use-btn {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.ocr-text-item.categorized .ocr-use-btn:hover {
    background: linear-gradient(135deg, #059669 0%, #047857 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(16, 185, 129, 0.3);
}


/* OCR Actions */
.ocr-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-bottom: 20px;
    padding: 15px;
    background: #f8fafc;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.btn-process-images {
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-process-images:hover:not(:disabled) {
    background: linear-gradient(135deg, #5a67d8, #6b46c1);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.btn-process-images:disabled {
    background: #cbd5e0;
    color: #a0aec0;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-clear-images {
    background: #e53e3e;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-clear-images:hover {
    background: #c53030;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(229, 62, 62, 0.3);
}

/* OCR Results */
.ocr-results {
    margin-top: 20px;
    padding: 20px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    max-height: 400px;
    overflow-y: auto;
    scroll-behavior: smooth;
}

/* OCR Guide */
.ocr-guide {
    margin-top: 20px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
}

/* QR Rehber Stilleri */
.qr-guide {
    margin-top: 20px;
    background: #f8fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 20px;
}

.qr-guide h4 {
    color: #4a5568;
    margin-bottom: 15px;
    font-size: 1.1rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.qr-guide h4 i {
    color: #667eea;
}

.guide-content {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.guide-item {
    padding: 12px;
    background: white;
    border-radius: 6px;
    border-left: 4px solid #667eea;
}

.guide-item strong {
    display: block;
    color: #2d3748;
    margin-bottom: 4px;
    font-size: 0.95rem;
}

.guide-item p {
    color: #718096;
    font-size: 0.9rem;
    margin: 0;
    line-height: 1.4;
}

.qr-upload-area.processing {
    border-color: #667eea;
    background: #f0f4ff;
    pointer-events: none;
}

.qr-upload-area.processing i {
    color: #667eea;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Kamera Stilleri */
.camera-modal-content {
    max-width: 600px;
}

#cameraVideo {
    width: 100%;
    max-width: 500px;
    border-radius: 8px;
    background: #000;
}

.camera-controls {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 20px;
}

/* Readonly Input Stilleri */
input[readonly] {
    background: #f1f5f9 !important;
    color: #4a5568 !important;
    cursor: not-allowed;
}

/* Buton Stilleri */
.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px 30px;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.btn-secondary {
    background: #718096;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.btn-secondary:hover {
    background: #4a5568;
    transform: translateY(-1px);
}

.btn-outline {
    background: transparent;
    color: #718096;
    border: 2px solid #e2e8f0;
    padding: 8px 16px;
    border-radius: 6px;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.btn-outline:hover {
    border-color: #cbd5e0;
    background: #f7fafc;
}

.btn-danger {
    background: #e53e3e;
    color: white;
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-danger:hover {
    background: #c53030;
    transform: translateY(-1px);
}

/* Arama Bölümü */
.search-controls {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.search-group {
    display: flex;
    gap: 10px;
    align-items: stretch;
}

.search-group input {
    flex: 1;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 1rem;
    background: #f8fafc;
    transition: all 0.3s ease;
}

.search-group input:focus {
    outline: none;
    border-color: #667eea;
    background: white;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.filter-group {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: center;
}

.filter-group select {
    padding: 10px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    background: #f8fafc;
    min-width: 150px;
    transition: all 0.3s ease;
}

.filter-group select:focus {
    outline: none;
    border-color: #667eea;
    background: white;
}

/* iPhone Listesi */
.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.stats {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.stat-item {
    background: #f7fafc;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    color: #4a5568;
    border: 2px solid #e2e8f0;
}

.phones-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 20px;
}

/* Phone Card Stilleri - YENİLENDİ */
.phone-card {
    background: white;
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
    border: 1px solid #e9ecef;
    position: relative;
    overflow: hidden;
}

.phone-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #007bff, #28a745, #ffc107);
}

.phone-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 30px rgba(0,0,0,0.12);
}

.phone-card.duplicate {
    border-color: #f56565;
    background: #fed7d7;
}

.phone-card.duplicate::before {
    content: "DUPLIKASYON!";
    position: absolute;
    top: -10px;
    right: 15px;
    background: #e53e3e;
    color: white;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

/* Phone Header */
.phone-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 2px solid #f8f9fa;
}

.phone-info {
    flex: 1;
}

.phone-model {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.phone-model i {
    color: #6c757d;
    font-size: 1.3rem;
}

.phone-specs {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.spec-badge {
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
}

.spec-badge.storage {
    background: #e3f2fd;
    color: #1976d2;
}

.spec-badge.color {
    background: #f3e5f5;
    color: #7b1fa2;
}

.phone-imei {
    font-size: 0.9rem;
    color: #6c757d;
    font-family: 'Monaco', 'Menlo', 'Courier New', monospace;
    background: #f8f9fa;
    padding: 8px 12px;
    border-radius: 6px;
    border-left: 3px solid #007bff;
}

.phone-actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.btn-icon {
    background: none;
    border: none;
    padding: 10px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    color: #6c757d;
    min-width: 40px;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-icon:hover {
    transform: translateY(-2px);
}

.btn-icon.edit {
    background: #28a745;
    color: white;
}

.btn-icon.edit:hover {
    background: #218838;
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.3);
}

.btn-icon.delete {
    background: #dc3545;
    color: white;
}

.btn-icon.delete:hover {
    background: #c82333;
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

/* Phone Details - Yeni Seksiyonlu Tasarım */
.phone-details {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.detail-section {
    background: #f8f9fa;
    border-radius: 12px;
    padding: 16px;
    border: 1px solid #e9ecef;
}

.detail-section h4 {
    margin: 0 0 12px 0;
    font-size: 1rem;
    font-weight: 600;
    color: #495057;
    display: flex;
    align-items: center;
    gap: 8px;
}

.detail-section h4 i {
    color: #007bff;
    width: 16px;
}

.detail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.detail-item {
    background: white;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
    transition: all 0.2s ease;
}

.detail-item:hover {
    border-color: #007bff;
    transform: translateY(-1px);
}

.detail-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #6c757d;
    text-transform: uppercase;
    margin-bottom: 6px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.detail-label i {
    width: 12px;
    color: #007bff;
}

.detail-value {
    font-size: 0.95rem;
    color: #2c3e50;
    font-weight: 500;
    word-break: break-word;
}

/* Değer Tipleri */
.not-available {
    color: #adb5bd;
    font-style: italic;
}

.price-value {
    color: #28a745;
    font-weight: 700;
}

.mac-address, .imei-value {
    font-family: 'Monaco', 'Menlo', 'Courier New', monospace;
    background: #e9ecef;
    padding: 2px 6px;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.2s;
    font-size: 0.85rem;
}

.mac-address:hover, .imei-value:hover {
    background: #007bff;
    color: white;
}

.battery-health {
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.85rem;
}

.battery-good {
    background: #d4edda;
    color: #155724;
}

.battery-medium {
    background: #fff3cd;
    color: #856404;
}

.battery-low {
    background: #f8d7da;
    color: #721c24;
}

.condition-status {
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
}

.condition-new {
    background: #d4edda;
    color: #155724;
}

.condition-good {
    background: #cce5ff;
    color: #0056b3;
}

.condition-medium {
    background: #fff3cd;
    color: #856404;
}

.condition-poor {
    background: #f8d7da;
    color: #721c24;
}

/* Phone Notes */
.phone-notes {
    background: linear-gradient(135deg, #fff3cd, #ffeaa7);
    border: 1px solid #ffeaa7;
    padding: 16px;
    border-radius: 12px;
    margin: 16px 0;
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.phone-notes i {
    color: #856404;
    margin-top: 2px;
    flex-shrink: 0;
}

.phone-notes span {
    color: #856404;
    font-style: italic;
    line-height: 1.4;
}

/* Phone Footer */
.phone-footer {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 2px solid #f8f9fa;
}

.phone-date {
    font-size: 0.85rem;
    color: #6c757d;
    text-align: right;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 8px;
    font-weight: 500;
}

.phone-date i {
    color: #007bff;
}

.phone-notes {
    background: white;
    padding: 10px;
    border-radius: 6px;
    font-size: 0.9rem;
    color: #4a5568;
    border-left: 4px solid #667eea;
    margin-top: 10px;
}

.phone-date {
    text-align: right;
    font-size: 0.8rem;
    color: #a0aec0;
    margin-top: 10px;
}

/* Telefon Fotoğrafları */
.phone-photos {
    margin-top: 15px;
}

.photos-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    max-width: 200px;
}

.photo-thumbnail {
    position: relative;
    aspect-ratio: 1;
    border-radius: 6px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.photo-thumbnail:hover {
    transform: scale(1.05);
}

.photo-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.photo-count {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0,0,0,0.7);
    color: white;
    font-size: 0.8rem;
    font-weight: bold;
    border-radius: 6px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #a0aec0;
    grid-column: 1 / -1;
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state p {
    font-size: 1.1rem;
    margin-bottom: 10px;
}

/* Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background-color: white;
    margin: 10% auto;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    animation: slideIn 0.3s ease;
    scroll-behavior: smooth;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 2px solid #e2e8f0;
}

.modal-header h3 {
    color: #e53e3e;
    font-size: 1.3rem;
}

.modal-header h3 i {
    margin-right: 10px;
}

.close {
    color: #a0aec0;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    transition: color 0.3s ease;
}

.close:hover {
    color: #4a5568;
}

.modal-body {
    padding: 25px;
    max-height: 60vh;
    overflow-y: auto;
    scroll-behavior: smooth;
}

.duplicate-info {
    background: #f7fafc;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 15px;
    margin: 15px 0;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 20px 25px;
    border-top: 2px solid #e2e8f0;
}

/* Animasyonlar */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* ============================================================================
   RESPONSIVE MOBILE DESIGN - TAMAMEN YENİLENDİ
   ============================================================================ */

/* Tablet ve Küçük Desktop (768px - 1024px) */
@media (max-width: 1024px) {
    .container {
        max-width: 100%;
        padding: 15px;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .form-row {
        grid-template-columns: 1fr 1fr;
        gap: 15px;
    }
}

/* Tablet Portrait (768px ve altı) */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
    
    /* Header Mobil */
    header {
        margin-bottom: 25px;
        padding: 20px 10px;
    }
    
    header h1 {
        font-size: 1.8rem;
        margin-bottom: 8px;
    }
    
    header h1 i {
        margin-right: 10px;
    }
    
    header p {
        font-size: 0.95rem;
        line-height: 1.5;
        padding: 0 10px;
    }
    
    /* Section Mobil */
    section {
        margin-bottom: 20px;
        padding: 20px 15px;
        border-radius: 12px;
    }
    
    section h2 {
        font-size: 1.3rem;
        margin-bottom: 15px;
    }
    
    /* Form Mobil */
    .image-upload-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .upload-area {
        padding: 30px 20px;
        min-height: 120px;
    }
    
    .upload-area i {
        font-size: 2rem;
    }
    
    .upload-area p {
        font-size: 1rem;
        margin: 10px 0 5px 0;
    }
    
    .upload-area small {
        font-size: 0.85rem;
    }
    
    /* OCR Actions Mobil */
    .ocr-actions {
        flex-direction: column;
        gap: 12px;
        padding: 15px;
    }
    
    .btn-process-images,
    .btn-clear-images {
        width: 100%;
        padding: 12px;
        font-size: 0.95rem;
    }
    
    /* Form Grid Mobil */
    .form-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .form-group {
        margin-bottom: 15px;
    }
    
    .form-group label {
        font-size: 0.9rem;
        margin-bottom: 6px;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 12px;
        font-size: 16px; /* iOS zoom önleme */
        border-radius: 8px;
    }
    
    /* Buttons Mobil */
    .btn {
        padding: 12px 20px;
        font-size: 0.95rem;
        border-radius: 8px;
    }
    
    .btn-submit {
        width: 100%;
        padding: 15px;
        font-size: 1.1rem;
        margin-top: 20px;
    }
    
    /* Search Controls Mobil */
    .search-controls {
        flex-direction: column;
        gap: 12px;
        padding: 15px;
    }
    
    .search-input-group {
        width: 100%;
    }
    
    .search-input-group input {
        font-size: 16px; /* iOS zoom önleme */
    }
    
    .filters {
        flex-direction: column;
        gap: 10px;
    }
    
    .filters select {
        font-size: 16px; /* iOS zoom önleme */
    }
    
    /* Section Header Mobil */
    .section-header {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .stats {
        justify-content: space-around;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .stat-item {
        font-size: 0.9rem;
        padding: 8px 12px;
    }
    
    /* Phone List Mobil */
    .phones-list {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .phone-card {
        padding: 15px;
    }
    
    .phone-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .phone-actions {
        align-self: flex-end;
    }
    
    .phone-model {
        font-size: 1.1rem;
    }
    
    .phone-imei {
        font-size: 0.85rem;
        word-break: break-all;
    }
    
    .phone-details {
        grid-template-columns: 1fr 1fr;
        gap: 12px;
        margin: 15px 0;
    }
    
    .detail-item {
        padding: 8px;
    }
    
    .detail-label {
        font-size: 0.8rem;
    }
    
    .detail-value {
        font-size: 0.9rem;
    }
}

/* Mobile Portrait (480px ve altı) - iPhone SE, küçük telefonlar */
@media (max-width: 480px) {
    .container {
        padding: 8px;
    }
    
    /* Header Ultra Mobil */
    header {
        margin-bottom: 20px;
        padding: 15px 5px;
    }
    
    header h1 {
        font-size: 1.5rem;
        margin-bottom: 6px;
    }
    
    header h1 i {
        margin-right: 8px;
        font-size: 1.3rem;
    }
    
    header p {
        font-size: 0.9rem;
        line-height: 1.4;
        padding: 0 5px;
    }
    
    /* Section Ultra Mobil */
    section {
        padding: 15px 12px;
        margin-bottom: 15px;
        border-radius: 10px;
    }
    
    section h2 {
        font-size: 1.2rem;
        margin-bottom: 12px;
    }
    
    section h3 {
        font-size: 1.1rem;
        margin-bottom: 10px;
    }
    
    /* Upload Ultra Mobil */
    .upload-area {
        padding: 25px 15px;
        min-height: 100px;
    }
    
    .upload-area i {
        font-size: 1.8rem;
    }
    
    .upload-area p {
        font-size: 0.95rem;
        margin: 8px 0 4px 0;
    }
    
    .upload-area small {
        font-size: 0.8rem;
    }
    
    /* Form Ultra Mobil */
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 14px 12px;
        font-size: 16px; /* iOS zoom önleme kritik */
    }
    
    .form-group label {
        font-size: 0.85rem;
        margin-bottom: 5px;
    }
    
    /* Phone Details Ultra Mobil */
    .phone-details {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .detail-item {
        padding: 6px 8px;
        border-radius: 6px;
    }
    
    .detail-label {
        font-size: 0.75rem;
    }
    
    .detail-value {
        font-size: 0.85rem;
        word-break: break-word;
    }
    
    /* Buttons Ultra Mobil */
    .btn {
        padding: 12px 16px;
        font-size: 0.9rem;
    }
    
    .btn-icon {
        padding: 10px;
        font-size: 0.9rem;
    }
    
    /* OCR Actions Ultra Mobil */
    .ocr-actions {
        padding: 12px;
        gap: 10px;
    }
    
    /* Search Ultra Mobil */
    .search-controls {
        padding: 12px;
        gap: 10px;
    }
    
    .search-input-group input {
        padding: 12px;
    }
    
    /* Stats Ultra Mobil */
    .stats {
        justify-content: center;
        gap: 8px;
    }
    
    .stat-item {
        font-size: 0.8rem;
        padding: 6px 10px;
    }
}

/* Ultra Small Devices (320px ve altı) - Çok eski telefonlar */
@media (max-width: 320px) {
    header h1 {
        font-size: 1.3rem;
    }
    
    header p {
        font-size: 0.85rem;
    }
    
    section {
        padding: 12px 8px;
    }
    
    .upload-area {
        padding: 20px 10px;
        min-height: 80px;
    }
    
    .upload-area i {
        font-size: 1.5rem;
    }
    
    .form-group input,
    .form-group select,
    .form-group textarea {
        padding: 12px 10px;
    }
}

/* iOS Safari Özel Düzeltmeler */
@supports (-webkit-touch-callout: none) {
    /* iOS Safari için özel stiller */
    .form-group input,
    .form-group select {
        -webkit-appearance: none;
        border-radius: 8px;
    }
    
    /* iOS'ta zoom önleme */
    .form-group input[type="text"],
    .form-group input[type="email"],
    .form-group input[type="tel"],
    .form-group select {
        font-size: 16px !important;
    }
}

/* Touch Device Optimizations */
@media (hover: none) and (pointer: coarse) {
    /* Touch cihazlar için daha büyük dokunma alanları */
    .btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    .btn-icon {
        min-height: 40px;
        min-width: 40px;
    }
    
    .upload-area {
        min-height: 120px;
    }
    
    /* Touch feedback */
    .btn:active,
    .upload-area:active {
        transform: scale(0.98);
        transition: transform 0.1s ease;
    }
}
