.container {
        background: linear-gradient(180deg, #6630C6 0%, #330F95 100%);
    max-width: 900px;
    margin: 0 auto;
    padding: 17px;
    border-radius: 10px;
}

.containers {
    max-width: 900px;
    margin: 0 auto;
    padding: 24px 24px;
    background: whitesmoke;
    border-radius: 10px;
}

/* ===== Header ===== */
/* .header {
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
} */

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.2rem;
  font-weight: 700;
  color: #1a6fdb;
  letter-spacing: -0.3px;
}

/* .nav {
  display: flex;
  gap: 24px;
}

.nav a {
  color: #64748b;
  font-size: 0.9rem;
  font-weight: 500;
  transition: color 0.2s;
}

.nav a:hover { color: #1a6fdb; } */

/* ===== Hero ===== */
.hero {
/*   background: linear-gradient(135deg, #1a6fdb 0%, #1558c0 100%); */
/*   padding: 20px 0 36px; */
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* .hero::before {
  content: '';
  position: absolute;
  top: -80px;
  right: -80px;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(255,255,255,0.05);
  pointer-events: none;
}

.hero::after {
  content: '';
  position: absolute;
  bottom: -60px;
  left: -60px;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: rgba(255,255,255,0.04);
  pointer-events: none;
} */

/* .hero-badge {
  display: inline-block;
  background: rgba(255,255,255,0.15);
  color: #bfdbfe;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 4px 14px;
  border-radius: 20px;
  margin-bottom: 16px;
  border: 1px solid rgba(255,255,255,0.2);
} */

.hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 14px;
  letter-spacing: -0.5px;
  line-height: 1.2;
}

.hero-sub {
  color: #bfdbfe;
  font-size: 1rem;
  max-width: 540px;
  margin: 0 auto;
  line-height: 1.6;
}

/* ===== Tool Section ===== */
.tool-section {
  padding: 40px 0 32px;
/*   background: #f8fafc; */
}

/* ===== Upload Box ===== */
.upload-box {
/*   background: #ffffff; */
  border: 2.5px dashed #93c5fd;
  border-radius: 16px;
  padding: 48px 24px;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.25s, background 0.25s, box-shadow 0.25s;
  box-shadow: 0 1px 3px rgba(0,0,0,0.08), 0 1px 2px rgba(0,0,0,0.06);
  position: relative;
}

.upload-box:hover,
.upload-box.drag-over {
  border-color: #1a6fdb;
  background: #eff6ff;
  box-shadow: 0 0 0 4px rgba(26,111,219,0.08);
}

.upload-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  pointer-events: none;
}

.upload-icon { margin-bottom: 4px; }

.upload-title {
  font-size: 1.15rem !important;
  font-weight: 600;
  color: #334155 !important;
}

.browse-link {
  color: #1a6fdb !important;
  cursor: pointer !important;
  text-decoration: underline;
  pointer-events: auto;
}

.browse-link:hover { color: #2563eb; }

.upload-sub {
  color: #94a3b8;
  font-size: 0.85rem;
}

#fileInput {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}

/* ===== Images Grid ===== */
.images-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 28px;
}

/* ===== Images Grid ===== */
.images-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
  margin-top: 28px;
}

/* ===== Image Card ===== */
.image-card {
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.05);
  overflow: hidden;
  border: 1px solid #e2e8f0;
  transition: transform 0.2s, box-shadow 0.2s;
  animation: fadeInUp 0.3s ease both;
}

.image-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0,0,0,0.1), 0 4px 12px rgba(0,0,0,0.06);
}

@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.card-preview {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
  background: #f1f5f9;
}

.card-body {
  padding: 14px 16px;
}

.card-filename {
  font-size: 0.85rem;
  font-weight: 600;
  color: #334155;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 10px;
}

.card-sizes {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.8rem;
  margin-bottom: 12px;
}

.size-badge {
  padding: 3px 10px !important;
  border-radius: 20px !important;
  font-weight: 600;
  font-size: 0.78rem;
}

.size-badge.original {
  background: #f1f5f9;
  color: #475569;
}

.size-badge.compressed {
  background: #f0fdf4 !important;
  color: #16a34a !important;
}

.size-arrow {
  color: #94a3b8 !important;
  font-size: 0.9rem;
}

.card-savings {
  font-size: 0.75rem;
  color: #16a34a !important;
  font-weight: 500;
}

.card-status {
  font-size: 0.78rem;
  color: #94a3b8;
  font-style: italic;
}

.card-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.btn-card-compress {
  flex: 1;
  padding: 8px 12px;
  background: #1a6fdb !important;
  color: white !important;
  border: none !important;
  border-radius: 8px !important;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  font-family: inherit;
}

.btn-card-compress:hover { background: #1d4ed8; }
.btn-card-compress:active { transform: scale(0.97); }
.btn-card-compress:disabled { background: #cbd5e1; cursor: not-allowed; }

.btn-card-download {
  padding: 8px 12px !important;
  background: #f0fdf4 !important;
  color: #16a34a !important;
  border: 1.5px solid #22c55e;
  border-radius: 8px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  display: flex;
  align-items: center;
  gap: 5px;
  font-family: inherit;
  white-space: nowrap;
}

.btn-card-download:hover { background: #dcfce7; }
.btn-card-download:active { transform: scale(0.97); }

.btn-card-remove {
  padding: 8px 10px !important;
  background: #fef2f2 !important;
  color: #ef4444 !important;
  border: 1.5px solid #fecaca !important;
  border-radius: 8px !important;
  font-size: 0.78rem;
  cursor: pointer;
  transition: background 0.2s;
  font-family: inherit;
  display: flex;
  align-items: center;
}

.btn-card-remove:hover { background: #fee2e2; }

/* Progress bar */
.progress-wrap {
  height: 4px;
  background: #f1f5f9 !important;
  border-radius: 2px !important;
  overflow: hidden;
  margin-top: 10px;
}

.progress-bar {
  height: 100%;
  background: linear-gradient(90deg, #60a5fa, #1a6fdb);
  border-radius: 2px !important;
  transition: width 0.4s ease;
  width: 0%;
}

/* ===== Global Controls ===== */
.global-controls {
  display: none;
  background: #ffffff;
  border-radius: 12px;
  padding: 24px;
  margin-top: 28px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.05);
  border: 1px solid #e2e8f0;
}

.global-controls.visible { display: block; }

.target-row {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}

.target-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: #334155;
  white-space: nowrap;
}

.size-inputs {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.size-input-group {
  display: flex;
  align-items: center;
  background: #f8fafc;
  border: 1.5px solid #e2e8f0;
  border-radius: 8px;
  overflow: hidden;
  transition: border-color 0.2s;
}

.size-input-group:focus-within { border-color: #1a6fdb; }

.size-input-group input {
  border: none;
  background: transparent;
  padding: 8px 10px;
  font-size: 0.9rem;
  width: 90px;
  font-family: inherit;
  color: #1e293b;
  outline: none;
}

.size-unit {
  background: #f1f5f9;
  padding: 8px 12px;
  font-size: 0.78rem;
  font-weight: 700;
  color: #64748b;
  letter-spacing: 0.05em;
  border-left: 1px solid #e2e8f0;
}

.size-sep {
  font-size: 0.82rem;
  color: #94a3b8;
  font-weight: 500;
}

.action-row {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
  align-items: center;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 22px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  font-family: inherit;
  white-space: nowrap;
}

.btn:active { transform: scale(0.97); }

.btn-primary {
  background: #1a6fdb !important;
  color: white !important;
  box-shadow: 0 2px 8px rgba(26,111,219,0.3);
}

.btn-primary:hover {
  background: #1d4ed8;
  box-shadow: 0 4px 14px rgba(26,111,219,0.4);
}

.btn-outline {
  background: white;
  color: #1a6fdb !important;
  border: 2px solid #1a6fdb !important;
}

.btn-outline:hover { background: #eff6ff; }

.btn-ghost {
  background: transparent !important;
  color: #64748b !important;
  border: 2px solid #e2e8f0 !important;
}

.btn-ghost:hover {
  background: #f1f5f9;
  color: #334155;
}

/* ===== Info Section ===== */
.info-section {
  padding: 56px 0;
/*   background: #ffffff; */
}

.section-title {
  text-align: center;
  font-size: 1.5rem !important;
  font-weight: 700 !important;
  color: #1e293b;
  margin-bottom: 36px;
  letter-spacing: -0.3px;
}

.info-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
}

.info-card {
  background: #f8fafc;
  border-radius: 12px;
  padding: 28px 24px;
  border: 1px solid #e2e8f0;
  transition: box-shadow 0.2s, transform 0.2s;
}

.info-card:hover {
  box-shadow: 0 4px 12px rgba(0,0,0,0.08), 0 2px 6px rgba(0,0,0,0.05);
  transform: translateY(-3px);
}

.info-icon {
  width: 52px;
  height: 52px;
  background: #eff6ff;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
}

.info-card h3 {
  font-size: 1rem !important;
  font-weight: 700 !important;
  color: #1e293b;
  margin-bottom: 8px;
}

.info-card p {
  font-size: 0.87rem;
  color: #64748b;
  line-height: 1.6;
}

/* ===== Footer ===== */
.footer {
  background: #1e293b;
  color: #94a3b8;
  padding: 24px 0;
  text-align: center;
  font-size: 0.85rem;
}

/* ===== Toast ===== */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(80px);
  background: #1e293b;
  color: white;
  padding: 12px 24px;
  border-radius: 40px;
  font-size: 0.88rem;
  font-weight: 500;
  box-shadow: 0 10px 30px rgba(0,0,0,0.1), 0 4px 12px rgba(0,0,0,0.06);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s;
  opacity: 0;
  z-index: 999;
  white-space: nowrap;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.toast.success { background: #16a34a; }
.toast.error { background: #ef4444; }

/* ===== Responsive ===== */
@media (max-width: 600px) {
.containers {
    max-width: 900px;
    margin: 0 auto;
    padding: 24px 6px !important;
    background: whitesmoke;
    border-radius: 10px;
}
	.card-actions{
		    display: block !important;
		justify-items:center;
	}
	.btn-card-compress, .btn-card-download, .btn-card-remove{
		margin:10px !important;
	}
  .hero { padding: 36px 0 32px; }
  .upload-box { padding: 32px 16px; }
  .target-row { flex-direction: column; align-items: flex-start; gap: 10px; }
  .action-row { width: 100%; }
  .btn { width: 100%; justify-content: center; }
  .global-controls { padding: 18px; }
  .images-grid { grid-template-columns: 1fr; }
}

@media (max-width: 400px) {
  .size-inputs { flex-direction: column; align-items: flex-start; }
}

/* ===== Spinning loader ===== */
.spinner {
  display: inline-block;
  width: 14px;
  height: 14px;
  border: 2px solid rgba(255,255,255,0.4);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}
