/* XecoStudio Global Stylesheet v1.4 */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  background-color: #ffffff;
  color: #1a1a1a;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: #2563eb;
  text-decoration: none;
}

a:hover {
  color: #1d4ed8;
  text-decoration: underline;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
summary:focus-visible {
  outline: 2px solid #2563eb;
  outline-offset: 2px;
}

[hidden] {
  display: none !important;
}

/* Layout Container */
.container {
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 0 16px;
}

@media (min-width: 640px) {
  .container {
    padding: 0 24px;
  }
}

main {
  flex: 1;
  padding-top: 24px;
  padding-bottom: 48px;
}

@media (min-width: 640px) {
  main {
    padding-top: 36px;
    padding-bottom: 64px;
  }
}

/* Header */
.site-header {
  border-bottom: 1px solid #e5e7eb;
  background-color: #ffffff;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: #1a1a1a;
  font-weight: 700;
  font-size: 1.0625rem;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.brand-link:hover {
  color: #2563eb;
  text-decoration: none;
}

.brand-mark {
  width: 24px;
  height: 24px;
  border-radius: 5px;
  flex-shrink: 0;
}

/* Typography & Section Spacing */
h1 {
  font-size: 1.625rem; /* 26px mobile */
  line-height: 1.25;
  letter-spacing: -0.02em;
  margin: 0 0 10px 0;
  color: #1a1a1a;
}

@media (min-width: 640px) {
  h1 {
    font-size: 2rem; /* 32px desktop */
  }
}

h2 {
  font-size: 1.375rem; /* 22px */
  line-height: 1.35;
  letter-spacing: -0.01em;
  margin: 0 0 16px 0;
  color: #1a1a1a;
}

h3 {
  font-size: 1.0625rem;
  line-height: 1.4;
  margin: 0 0 6px 0;
  color: #1a1a1a;
}

p {
  margin: 0 0 16px 0;
}

.lead {
  font-size: 1rem;
  color: #5f6368;
  margin: 0;
}

.section {
  margin-top: 32px;
}

@media (min-width: 640px) {
  .section {
    margin-top: 48px;
  }
}

/* Breadcrumb */
.breadcrumb {
  font-size: 0.875rem;
  color: #5f6368;
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}

.breadcrumb a {
  color: #5f6368;
}

.breadcrumb a:hover {
  color: #2563eb;
}

.breadcrumb__sep {
  color: #6b7280;
}

/* Tool Cards (Homepage & More Tools) */
.tool-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.tool-card {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 18px 20px;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  background-color: #ffffff;
  color: #1a1a1a;
  text-decoration: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

a.tool-card:hover {
  border-color: #2563eb;
  box-shadow: 0 2px 8px rgba(37, 99, 235, 0.08);
  text-decoration: none;
  color: #1a1a1a;
}

.tool-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.tool-card__title {
  font-size: 1.0625rem;
  font-weight: 600;
  margin: 0;
  color: inherit;
}

a.tool-card:hover .tool-card__title {
  color: #2563eb;
}

.tool-card__arrow {
  color: #2563eb;
  font-weight: 600;
  font-size: 1rem;
  flex-shrink: 0;
}

.tool-card__desc {
  margin: 0;
  font-size: 0.875rem;
  color: #5f6368;
}

.tool-card--disabled {
  background-color: #f8fafc;
  color: #5f6368;
  cursor: default;
}

.tool-card--disabled .tool-card__title {
  color: #5f6368;
}

.badge-soon {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 500;
  color: #5f6368;
  background-color: #e5e7eb;
  padding: 2px 8px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}

.back-all-link {
  display: inline-block;
  margin-top: 14px;
  font-size: 0.875rem;
  font-weight: 500;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 8px;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.2;
  cursor: pointer;
  border: 1px solid transparent;
  text-decoration: none;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
  user-select: none;
}

.btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-primary {
  background-color: #2563eb;
  color: #ffffff;
}

.btn-primary:hover:not(:disabled) {
  background-color: #1d4ed8;
  color: #ffffff;
  text-decoration: none;
}

.btn-secondary {
  background-color: #ffffff;
  color: #1a1a1a;
  border-color: #d1d5db;
}

.btn-secondary:hover:not(:disabled) {
  border-color: #2563eb;
  color: #2563eb;
  text-decoration: none;
}

.btn-outline-primary {
  background-color: #ffffff;
  color: #2563eb;
  border-color: #2563eb;
}

.btn-outline-primary:hover:not(:disabled) {
  background-color: #eff6ff;
  color: #1d4ed8;
  text-decoration: none;
}

.btn-block {
  width: 100%;
}

.btn-sm {
  min-height: 44px;
  padding: 8px 14px;
  font-size: 0.875rem;
}

.btn-link-muted {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  padding: 8px 12px;
  min-height: 44px;
  font-family: inherit;
  font-size: 0.875rem;
  font-weight: 500;
  color: #5f6368;
  cursor: pointer;
  border-radius: 8px;
}

.btn-link-muted:hover:not(:disabled) {
  color: #b91c1c;
  background-color: #fef2f2;
}

.btn-link-muted:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

/* Tool Workspace */
.tool-workspace {
  margin-top: 24px;
}

/* Dropzone */
.dropzone {
  border: 2px dashed #cbd5e1;
  border-radius: 12px;
  min-height: 180px;
  padding: 24px 16px;
  background-color: #f8fafc;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 10px;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease;
}

.dropzone:hover,
.dropzone.is-dragover {
  border-color: #2563eb;
  background-color: #eff6ff;
}

.dropzone.is-disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}

.dropzone__icon {
  width: 36px;
  height: 36px;
  color: #2563eb;
}

.dropzone__title {
  margin: 0;
  font-size: 1.0625rem;
  font-weight: 600;
  color: #1a1a1a;
}

.dropzone__sub {
  margin: 0;
  font-size: 0.875rem;
  color: #5f6368;
}

/* Intake Notice */
.notice-banner {
  margin-top: 12px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.875rem;
  border: 1px solid #fde68a;
  background-color: #fffbeb;
  color: #92400e;
}

.notice-banner--error {
  border-color: #fecaca;
  background-color: #fef2f2;
  color: #b91c1c;
}

/* File List & Result List */
.panel-block {
  margin-top: 18px;
}

.list-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.list-count {
  font-size: 0.875rem;
  font-weight: 600;
  color: #1a1a1a;
}

.item-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.file-row,
.result-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background-color: #ffffff;
  min-width: 0;
}

.file-row__icon {
  width: 36px;
  height: 36px;
  border-radius: 6px;
  background-color: #f3f4f6;
  color: #5f6368;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.result-row__thumb {
  width: 48px;
  height: 48px;
  border-radius: 6px;
  object-fit: cover;
  background-color: #f3f4f6;
  border: 1px solid #e5e7eb;
  flex-shrink: 0;
}

.result-row__error-icon {
  width: 40px;
  height: 40px;
  border-radius: 6px;
  background-color: #fef2f2;
  color: #b91c1c;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.row-meta {
  flex: 1;
  min-width: 0;
}

.row-name {
  font-size: 0.9375rem;
  font-weight: 500;
  color: #1a1a1a;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: block;
}

.row-sub {
  font-size: 0.8125rem;
  color: #5f6368;
  display: block;
  margin-top: 2px;
}

.row-sub--done {
  color: #15803d;
}

.row-sub--error {
  color: #b91c1c;
  white-space: normal;
  word-break: break-word;
}

.result-row--error {
  border-color: #fecaca;
  background-color: #fef2f2;
}

.btn-remove {
  width: 44px;
  height: 44px;
  min-height: 44px;
  border-radius: 8px;
  border: none;
  background: transparent;
  color: #5f6368;
  font-size: 1.25rem;
  line-height: 1;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.btn-remove:hover:not(:disabled) {
  background-color: #fef2f2;
  color: #b91c1c;
}

.btn-remove:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Options / Quality Slider */
.options-bar {
  margin-top: 18px;
  padding: 14px 16px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background-color: #f8fafc;
}

.quality-control {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.quality-label {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #1a1a1a;
}

.quality-slider {
  flex: 1;
  min-width: 140px;
  height: 24px;
  accent-color: #2563eb;
  cursor: pointer;
}

.quality-slider:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.quality-value {
  font-size: 0.9375rem;
  font-weight: 600;
  color: #2563eb;
  min-width: 42px;
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.quality-hint {
  margin: 8px 0 0 0;
  font-size: 0.8125rem;
  color: #b45309;
}

/* Action Area */
.action-bar {
  margin-top: 16px;
}

/* Progress Section */
.progress-panel {
  margin-top: 16px;
  padding: 14px 16px;
  border: 1px solid #dbeafe;
  border-radius: 10px;
  background-color: #eff6ff;
}

.progress-text {
  margin: 0 0 8px 0;
  font-size: 0.875rem;
  font-weight: 600;
  color: #1e40af;
}

.progress-track {
  width: 100%;
  height: 8px;
  background-color: #dbeafe;
  border-radius: 999px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  width: 0%;
  background-color: #2563eb;
  border-radius: 999px;
  transition: width 0.2s ease;
}

/* Results Header & Download All */
.results-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}

.results-title {
  font-size: 1rem;
  font-weight: 600;
  margin: 0;
}

.ios-tip {
  margin: 0 0 10px 0;
  font-size: 0.8125rem;
  color: #5f6368;
}

/* Trust Bar */
.trust-bar {
  margin-top: 18px;
  padding: 10px 12px;
  text-align: center;
  font-size: 0.875rem;
  color: #5f6368;
  background-color: #f8fafc;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

/* How It Works */
.steps-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

@media (min-width: 640px) {
  .steps-list {
    grid-template-columns: repeat(3, 1fr);
  }
}

.step-item {
  padding: 16px;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background-color: #ffffff;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

@media (min-width: 640px) {
  .step-item {
    flex-direction: column;
    gap: 8px;
  }
}

.step-num {
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background-color: #eff6ff;
  color: #2563eb;
  font-size: 0.875rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.step-text {
  font-size: 0.9375rem;
  font-weight: 500;
  color: #1a1a1a;
}

/* FAQ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.faq-item {
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  background-color: #ffffff;
  padding: 0 16px;
}

.faq-question {
  padding: 14px 0;
  font-size: 1rem;
  font-weight: 600;
  color: #1a1a1a;
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.faq-question::-webkit-details-marker {
  display: none;
}

.faq-question::after {
  content: "+";
  font-size: 1.25rem;
  font-weight: 400;
  color: #5f6368;
  flex-shrink: 0;
}

.faq-item[open] .faq-question::after {
  content: "−";
  color: #2563eb;
}

.faq-answer {
  padding: 0 0 14px 0;
  margin: 0;
  font-size: 0.9375rem;
  color: #5f6368;
  line-height: 1.65;
}

/* Legal & 404 Prose */
.legal-updated {
  font-size: 0.875rem;
  color: #5f6368;
  margin-bottom: 24px;
}

.legal-prose h2 {
  margin-top: 28px;
  margin-bottom: 10px;
  font-size: 1.1875rem;
}

.legal-prose p {
  color: #374151;
}

.not-found-box {
  padding: 36px 0;
}

.not-found-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}

/* Footer */
.site-footer {
  border-top: 1px solid #e5e7eb;
  padding: 24px 0;
  background-color: #ffffff;
  font-size: 0.875rem;
  color: #5f6368;
}

.site-footer__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.footer-nav {
  display: flex;
  align-items: center;
  gap: 18px;
}

.footer-nav a {
  color: #5f6368;
}

.footer-nav a:hover {
  color: #2563eb;
}
