/**
 * GABUNG.COM — Non-Critical Component & Utility Styles
 * Cached by Browser for Superfast Navigation
 */

/* 1. Tool Container & Centered Max-Width */
.tool-container {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 1.5rem;
  padding: 1.25rem;
  max-width: 54rem !important;
  margin: 1.25rem auto 2rem auto !important;
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.05);
  box-sizing: border-box;
  transition: all 0.2s ease;
}
@media (min-width: 640px) {
  .tool-container { padding: 2rem; }
}
html.dark .tool-container {
  background: #0f172a !important;
  border-color: #1e293b !important;
  box-shadow: none !important;
}

/* 2. Upload Dropzone & Proper Bottom Gap */
.upload-zone, #drop-zone {
  border: 2px dashed rgba(79, 70, 229, 0.4);
  border-radius: 1rem;
  padding: 2rem 1rem;
  text-align: center;
  background: #eef2ff;
  cursor: pointer;
  transition: all 0.2s ease;
  margin-bottom: 1.75rem !important;
}
@media (min-width: 640px) {
  .upload-zone, #drop-zone { padding: 3rem 1.5rem; margin-bottom: 2rem !important; }
}
.upload-zone:hover, .upload-zone.dragover {
  border-color: #4f46e5;
  background: #e0e7ff;
}
html.dark .upload-zone, html.dark #drop-zone {
  border-color: rgba(99, 102, 241, 0.35) !important;
  background: rgba(30, 27, 75, 0.3) !important;
}
.upload-zone-icon {
  font-size: 2.25rem;
  margin-bottom: 0.5rem;
  display: inline-block;
  transition: transform 0.2s ease;
}
.upload-zone:hover .upload-zone-icon {
  transform: scale(1.1);
}

/* 3. Compact Action Buttons (Single Line on Mobile) */
.btn, button.btn, a.btn, 
button[style*="padding"], a[style*="padding"] {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.35rem !important;
  font-weight: 700 !important;
  font-size: 0.85rem !important;
  padding: 0.65rem 1.25rem !important;
  border-radius: 0.75rem !important;
  cursor: pointer;
  text-decoration: none !important;
  white-space: nowrap !important;
  transition: all 0.2s ease;
}
@media (min-width: 640px) {
  .btn, button.btn, a.btn, 
  button[style*="padding"], a[style*="padding"] { 
    font-size: 0.925rem !important; 
    padding: 0.75rem 1.6rem !important; 
    border-radius: 0.875rem !important; 
  }
}
.btn-primary {
  background: #4f46e5 !important;
  color: #ffffff !important;
  box-shadow: 0 4px 14px 0 rgba(79, 70, 229, 0.35) !important;
  border: none !important;
}
.btn-primary:hover { background: #4338ca !important; transform: translateY(-1px); }
.btn-primary:disabled { opacity: 0.5 !important; cursor: not-allowed !important; transform: none !important; }

.btn-secondary {
  background: #f1f5f9 !important;
  color: #334155 !important;
  border: 1px solid #cbd5e1 !important;
}
html.dark .btn-secondary {
  background: #1e293b !important;
  color: #e2e8f0 !important;
  border-color: #334155 !important;
}

/* 4. Form Controls & Select Dropdown Fix */
input[type="text"], input[type="number"], select {
  width: 100%;
  border: 1px solid #cbd5e1;
  border-radius: 0.65rem;
  padding: 0.55rem 0.75rem;
  background: #ffffff;
  color: #0f172a;
  font-size: 0.875rem;
  outline: none;
  transition: all 0.2s;
}
.dark input[type="text"], .dark input[type="number"], .dark select {
  border-color: #334155;
  background: #0f172a;
  color: #f1f5f9;
}
select option { background-color: #ffffff; color: #0f172a; }
.dark select option { background-color: #0f172a; color: #f1f5f9; }

/* 5. Tool Options Grid */
.tool-options-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1rem;
  padding: 1rem;
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  margin: 1.5rem 0;
}
html.dark .tool-options-grid { background: #1e293b !important; border-color: #334155 !important; }

/* 6. Pas Foto & 2-Foto Mobile Overflows Fix */
.pasfoto-layout, div[style*="grid-template-columns: 1fr 340px"] {
  display: flex !important;
  flex-direction: column !important;
  gap: 1.5rem !important;
  align-items: center !important;
  width: 100% !important;
}
@media (min-width: 768px) {
  .pasfoto-layout, div[style*="grid-template-columns: 1fr 340px"] {
    display: grid !important;
    grid-template-columns: 1fr 320px !important;
    align-items: start !important;
  }
}
.dua-foto-slots, div[style*="grid-template-columns: 1fr 1fr"] {
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 1rem !important;
  width: 100% !important;
  box-sizing: border-box !important;
  overflow: hidden !important;
}
@media (min-width: 640px) {
  .dua-foto-slots, div[style*="grid-template-columns: 1fr 1fr"] { 
    grid-template-columns: 1fr 1fr !important;
    gap: 1.5rem !important; 
  }
}
.slot-box {
  border: 2px dashed rgba(79, 70, 229, 0.35);
  border-radius: 1rem;
  background: #f8fafc;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
}
html.dark .slot-box { background: #1e293b !important; border-color: #334155 !important; }

/* 7. Article & Visual Cards Layout */
article, article[style], .article-content {
  max-width: 54rem !important;
  margin: 2.5rem auto !important;
  padding-left: 1.25rem !important;
  padding-right: 1.25rem !important;
  box-sizing: border-box;
}
@media (min-width: 640px) {
  article, article[style], .article-content { padding-left: 1.5rem !important; padding-right: 1.5rem !important; }
}
.card {
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 1rem;
  padding: 1.25rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}
html.dark .card { background: #0f172a !important; border-color: #1e293b !important; }

/* 8. Subpage Header (Strict Center Alignment) */
.container > header, header.subpage-header {
  text-align: center !important;
  max-width: 46rem !important;
  margin-left: auto !important;
  margin-right: auto !important;
  margin-bottom: 2rem !important;
  padding-left: 1rem !important;
  padding-right: 1rem !important;
}
header p, header p[style] {
  font-size: 0.85rem !important;
  line-height: 1.5 !important;
  text-align: center !important;
  margin-top: 0.5rem !important;
}
@media (min-width: 640px) {
  header p, header p[style] { font-size: 0.975rem !important; }
}

.card-hover { transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1); }
.card-hover:hover { transform: translateY(-3px); box-shadow: 0 12px 24px -8px rgba(79, 70, 229, 0.18); }