/* ToolForYou - Passport Size Photo Maker Dedicated Styles */

:root {
  --primary-color: #2563eb;
  --primary-hover: #1d4ed8;
  --primary-light: #eff6ff;
  --border-color: #e2e8f0;
  --text-dark: #0f172a;
  --text-muted: #64748b;
  --bg-card: #ffffff;
  --bg-soft: #f8fafc;
}

/* Step Wizard Navigation */
.step-wizard-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  margin-bottom: 2rem;
  padding: 0 1rem;
}

.step-wizard-bar::before {
  content: "";
  position: absolute;
  top: 22px;
  left: 2rem;
  right: 2rem;
  height: 3px;
  background-color: var(--border-color);
  z-index: 1;
}

.step-wizard-item {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  color: var(--text-muted);
  transition: all 0.25s ease;
}

.step-wizard-item:disabled {
  cursor: not-allowed;
  opacity: 0.55;
}

.step-number {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: #ffffff;
  border: 3px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 15px;
  color: var(--text-muted);
  margin-bottom: 6px;
  transition: all 0.25s ease;
  box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.step-title {
  font-size: 13px;
  font-weight: 600;
  text-align: center;
  white-space: nowrap;
}

.step-wizard-item.active .step-number {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: #ffffff;
  transform: scale(1.12);
  box-shadow: 0 4px 10px rgba(37, 99, 235, 0.35);
}

.step-wizard-item.active .step-title {
  color: var(--primary-color);
  font-weight: 700;
}

.step-wizard-item.completed .step-number {
  background-color: #10b981;
  border-color: #10b981;
  color: #ffffff;
}

.step-wizard-item.completed .step-title {
  color: #10b981;
}

/* Preset Cards */
.preset-card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.preset-card {
  border: 2px solid var(--border-color);
  border-radius: 12px;
  padding: 14px 12px;
  text-align: left;
  cursor: pointer;
  background-color: #ffffff;
  transition: all 0.2s ease;
  position: relative;
}

.preset-card:hover {
  border-color: #93c5fd;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.08);
}

.preset-card.active {
  border-color: var(--primary-color);
  background-color: var(--primary-light);
  box-shadow: 0 0 0 1px var(--primary-color);
}

.preset-card .preset-dim {
  font-size: 15px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 2px;
}

.preset-card .preset-country {
  font-size: 12px;
  color: var(--text-muted);
  line-height: 1.3;
}

.preset-card .preset-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  position: absolute;
  top: 10px;
  right: 10px;
}

/* Interactive Crop Workspace */
.crop-viewport-container {
  position: relative;
  width: 100%;
  max-width: 440px;
  margin: 0 auto;
  aspect-ratio: 0.7777; /* Default 3.5:4.5 */
  background-color: #0f172a;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  user-select: none;
}

.crop-canvas-element {
  display: block;
  width: 100%;
  height: 100%;
  cursor: grab;
  touch-action: none;
}

.crop-canvas-element:active {
  cursor: grabbing;
}

/* Biometric Guidelines */
.face-guide-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  box-sizing: border-box;
}

.guide-oval {
  position: absolute;
  top: 15%;
  left: 17%;
  width: 66%;
  height: 60%;
  border: 2px dashed rgba(244, 63, 94, 0.85);
  border-radius: 50%;
  box-shadow: 0 0 0 9999px rgba(15, 23, 42, 0.35);
}

.guide-eye-line {
  position: absolute;
  top: 42%;
  left: 10%;
  width: 80%;
  height: 0;
  border-top: 1.5px dashed rgba(59, 130, 246, 0.85);
}

.guide-chin-line {
  position: absolute;
  top: 75%;
  left: 20%;
  width: 60%;
  height: 0;
  border-top: 1.5px dashed rgba(16, 185, 129, 0.85);
}

.guide-crown-line {
  position: absolute;
  top: 15%;
  left: 20%;
  width: 60%;
  height: 0;
  border-top: 1.5px dashed rgba(245, 158, 11, 0.85);
}

/* Controls Toolbars */
.editor-toolbar {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 8px 12px;
  background-color: #f8fafc;
  border: 1px solid var(--border-color);
  border-radius: 10px;
}

/* Clothing Overlays & Selection */
.clothing-category-nav {
  display: flex;
  gap: 8px;
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 8px;
  margin-bottom: 12px;
  overflow-x: auto;
}

.clothing-category-btn {
  padding: 6px 14px;
  border-radius: 20px;
  border: 1px solid var(--border-color);
  background-color: #ffffff;
  color: var(--text-dark);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
}

.clothing-category-btn.active {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: #ffffff;
}

.clothing-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  gap: 10px;
  max-height: 280px;
  overflow-y: auto;
  padding: 4px;
}

.clothing-item-card {
  border: 2px solid var(--border-color);
  border-radius: 10px;
  padding: 8px;
  text-align: center;
  cursor: pointer;
  background-color: #ffffff;
  transition: all 0.2s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.clothing-item-card:hover {
  border-color: #93c5fd;
  transform: translateY(-2px);
}

.clothing-item-card.active {
  border-color: var(--primary-color);
  background-color: var(--primary-light);
  box-shadow: 0 0 0 1px var(--primary-color);
}

.clothing-thumb-img {
  width: 60px;
  height: 50px;
  object-fit: contain;
  margin-bottom: 4px;
}

.clothing-item-card .clothing-title {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-dark);
  line-height: 1.2;
}

/* Background Color Chips */
.bg-color-grid {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.bg-color-item {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 2px solid #ffffff;
  box-shadow: 0 0 0 1.5px var(--border-color);
  cursor: pointer;
  position: relative;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bg-color-item:hover {
  transform: scale(1.1);
}

.bg-color-item.active {
  box-shadow: 0 0 0 2px var(--primary-color);
  transform: scale(1.08);
}

.bg-color-item.transparent-chip {
  background: repeating-conic-gradient(#cbd5e1 0% 25%, #f1f5f9 0% 50%) 50% / 10px 10px;
}

/* Print Sheet Preview */
.print-sheet-preview-wrapper {
  background-color: #475569;
  border-radius: 10px;
  padding: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  max-height: 480px;
  overflow: hidden;
}

.print-sheet-canvas-el {
  max-width: 100%;
  max-height: 440px;
  object-fit: contain;
  background-color: #ffffff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
  border-radius: 4px;
}

/* Mobile responsive tweaks */
@media (max-width: 768px) {
  .step-wizard-bar {
    padding: 0;
  }
  .step-wizard-bar::before {
    left: 1rem;
    right: 1rem;
    top: 18px;
  }
  .step-number {
    width: 36px;
    height: 36px;
    font-size: 13px;
  }
  .step-title {
    font-size: 11px;
  }
  .crop-viewport-container {
    max-width: 320px;
  }
}
