@import url("https://fonts.googleapis.com/css2?family=Comic+Neue:wght@400;700&display=swap");
:root {
  --primary-color: #eab308; /* Yellow theme for images */
  --primary-hover: #ca8a04;
  --bg-color: #f4f7f6;
  --card-bg: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --border-color: #e2e8f0;
  --font-main: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif;
  --font-comic: 'Comic Neue', 'Chalkboard SE', 'Marker Felt', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; font-family: var(--font-main); }
body { background-color: var(--bg-color); color: var(--text-main); min-height: 100vh; display: flex; flex-direction: column; }

/* Header & Sidebar */
.govt-header { background: #1b2537; color: #ffffff; padding: 12px 30px; border-bottom: 3px solid #2563eb; width: 100%; position: fixed; top: 0; left: 0; z-index: 1000; height: 80px; }
.header-container { max-width: 1400px; margin: 0 auto; display: flex; align-items: center; justify-content: space-between; height: 100%; }
.brand-logo { display: flex; align-items: center; gap: 14px; }
.brand-logo i { font-size: 32px; color: #38bdf8; }
.brand-logo h1 { font-size: 20px; font-weight: 700; color: #ffffff; }

.portal-layout { display: flex; width: 100%; margin-top: 80px; min-height: calc(100vh - 80px); }
.app-sidebar { width: 85px; background: #ffffff; border-right: 1px solid var(--border-color); display: flex; flex-direction: column; align-items: center; padding: 15px 0; gap: 12px; position: fixed; height: calc(100vh - 80px); top: 80px; left: 0; z-index: 100; overflow-y: auto; }
.nav-item { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 68px; height: 68px; border-radius: 12px; text-decoration: none; color: #64748b; font-size: 11px; font-weight: 600; gap: 6px; transition: 0.2s ease; text-align: center; }
.nav-item i { font-size: 20px; }
.nav-item:hover { background: #f8fafc; color: #2563eb; }
.nav-item.active { background: #eff6ff; color: #2563eb; }
.app-main { margin-left: 85px; flex: 1; padding: 35px; width: calc(100% - 85px); }

/* Layout Grid */
.tool-center-container { display: flex; justify-content: center; align-items: flex-start; }
.main-tool-card { width: 100%; max-width: 900px; }

/* Tool Title */
.dual-icon { position: relative; width: 66px; height: 62px; margin-bottom: 14px; flex-shrink: 0;}
.dual-icon .sq { position: absolute; width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 16px; }
.dual-icon .pos-tl { top: 0; left: 0; }
.dual-icon .pos-br { top: 22px; left: 26px; border: 2px solid #fff;}
.dual-icon.yellow .light { background: #fef08a; color: #854d0e; z-index: 1; }
.dual-icon.yellow .solid { background: #eab308; color: #fff; z-index: 2; }

[hidden] { display: none !important; }
.tool-title { display: flex; align-items: center; gap: 18px; margin-bottom: 22px; }
.tool-title h2 { font-size: 24px; font-weight: 700; color: #0f172a;}
.tool-title p { font-size: 14px; color: var(--text-muted); margin-top: 4px; }
.tool-box { background: var(--card-bg); border: 1px solid var(--border-color); border-radius: 20px; padding: 30px; box-shadow: 0 4px 20px rgba(0,0,0,0.05); }

/* Modern Cool Dropzone (Centered) */
.drop-zone { background: linear-gradient(145deg, #f8fafc, #fefce8); border: 2px dashed #fde047; border-radius: 24px; padding: 80px 20px; text-align: center; cursor: pointer; transition: all 0.3s ease; box-shadow: inset 0 0 20px rgba(255,255,255,0.8); display: flex; flex-direction: column; align-items: center; justify-content: center;}
.drop-zone:hover { border-color: var(--primary-hover); background: linear-gradient(145deg, #fefce8, #fef9c3); transform: translateY(-2px); }
.upload-icon-wrap { background: #fff; width: 90px; height: 90px; border-radius: 50%; display: flex; align-items: center; justify-content: center; margin-bottom: 20px; box-shadow: 0 8px 25px rgba(234, 179, 8, 0.2); }
.upload-icon-wrap i { font-size: 40px; color: var(--primary-color); }
.comic-text { font-family: var(--font-comic); font-size: 26px; margin-bottom: 8px; font-weight: 600; color: #854d0e; }
.drop-zone p { color: var(--text-muted); margin-bottom: 24px; font-size: 15px; }

/* Buttons */
.btn { border: 1px solid var(--border-color); background: #fff; color: var(--text-main); padding: 12px 24px; font-size: 14px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; transition: 0.2s; justify-content: center;}
.btn:hover { background: #f1f5f9; }
.btn.primary { background: var(--primary-color); border-color: var(--primary-color); color: #fff; }
.btn.primary:hover { background: var(--primary-hover); box-shadow: 0 4px 12px rgba(234, 179, 8, 0.25); }
.round-btn { border-radius: 50px !important; }
.btn:disabled { opacity: 0.6; cursor: not-allowed; }

/* Settings & Results Panel */
.file-info-bar { background: #fefce8; color: #854d0e; padding: 12px 18px; border-radius: 50px; font-size: 14px; font-weight: 600; margin-bottom: 20px; display: inline-flex; align-items: center; gap: 8px; border: 1px solid #fef08a; }
.settings-row { display: flex; flex-wrap: wrap; gap: 20px; margin-bottom: 25px; background: #f8fafc; padding: 20px; border-radius: 16px; border: 1px solid #e2e8f0; }
.setting-group { flex: 1; min-width: 200px; }
.setting-group label { display: block; font-size: 13px; font-weight: 600; color: #475569; margin-bottom: 8px; }
.pro-select, .pro-input { width: 100%; padding: 10px 14px; border: 1px solid #cbd5e1; font-size: 14px; outline: none; background: #fff; transition: 0.2s; }
.pro-select:focus, .pro-input:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(234,179,8,0.1); }
.round-input { border-radius: 50px; }

/* Results Grid */
.data-preview-box { background-color: #fff; border: 1px solid #cbd5e1; border-radius: 16px; padding: 20px; max-height: 400px; overflow: auto; box-shadow: inset 0 2px 10px rgba(0,0,0,0.02); }
.results-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 16px; }
.result-card { border: 1px solid var(--border-color); border-radius: 12px; padding: 10px; background: #f8fafc; display: flex; flex-direction: column; gap: 10px; transition: 0.2s;}
.result-card:hover { border-color: #cbd5e1; box-shadow: 0 4px 12px rgba(0,0,0,0.05); }
.result-card img { width: 100%; border-radius: 8px; border: 1px solid var(--border-color); background: #fff; }
.result-card .row { display: flex; justify-content: space-between; align-items: center; font-size: 12px; font-weight: 600; }
.result-card a { text-decoration: none; background: var(--primary-color); color: #fff; padding: 6px 12px; border-radius: 50px; font-size: 12px; transition: 0.2s;}
.result-card a:hover { background: var(--primary-hover); transform: scale(1.05); }

.status { margin-top: 14px; font-size: 14px; font-weight: 600; text-align: center;}
.status.error { color: #dc2626; }
.status.ok { color: #16a34a; }