/* photo-tools.css — shared light theme for Flash + Film tools */
:root{
  --bg: #f7f7f9;
  --surface: #ffffff;
  --ink: #111318;
  --muted: #6b7280;
  --accent: #ff1c5a;
  --accent-2: #ff7b9b;
  --border: #e5e7eb;
  --border-strong: #d6dae1;
  --shadow: 0 10px 30px rgba(0,0,0,.06);
  --radius: 16px;
}

*{ box-sizing: border-box }
html, body{ height: 100% }
body{
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial, "Apple Color Emoji", "Segoe UI Emoji";
  background: radial-gradient(1200px 800px at 10% 10%, #f2f3f6, var(--bg)) fixed;
  color: var(--ink);
  display: grid;
  place-items: center;
  padding: 24px;
}

/* App shell (card) */
.app{
  width: 100%;
  max-width: 980px;
  background: linear-gradient(180deg, rgba(255,255,255,.8), rgba(255,255,255,.9)), var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px 24px 18px;
}

/* Back button (consistent across tools) */
.back-btn{
  display: inline-flex;
  align-items: center;
  gap: .5rem;
  text-decoration: none;
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 12px;
  border: 1px solid var(--border);
  background: #fff;
  padding: 8px 12px;
  border-radius: 10px;
  transition: border-color .15s, transform .06s, color .15s, background .15s, box-shadow .15s;
}
.back-btn:hover{
  border-color: var(--border-strong);
  color: #b80f3a; /* slightly darker accent on hover */
  background: #fff7f9;
  transform: translateX(-1px);
  box-shadow: 0 6px 18px rgba(255, 28, 90, .12);
}
.back-btn .arrow{ font-size: 1.1rem; line-height: 1 }

/* Headers */
header{ display: grid; gap: 6px; margin-bottom: 16px }
header h1{ margin: 0; font-size: clamp(22px, 3.6vw, 28px); letter-spacing: .2px }
header p{ margin: 0; color: var(--muted); font-size: 14px }

/* Layout */
.grid{ display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)) }

/* Cards */
.card{
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}
.card h2{ margin: 0 0 12px; font-size: 16px; color: #2c2f36; letter-spacing: .2px }
.card label{ font-weight: 600; font-size: .92rem; color: #2c2f36; display: block; margin-bottom: .4rem }

/* Inputs (framed to match both tools) */
.number{
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px 12px;
}
.number input[type="number"],
.number input[type="text"]{
  width: 100%;
  border: none;
  outline: none;
  background: transparent;
  color: var(--ink);
  font-size: 18px;
  appearance: textfield;
}
input[type="number"]::-webkit-outer-spin-button,
input[type="number"]::-webkit-inner-spin-button{ -webkit-appearance:none; margin:0 }

/* Range slider (Flash tool) */
.slider input[type="range"]{
  width: 100%;
  appearance: none;
  height: 6px;
  border-radius: 999px;
  background: #eceef2;
  outline: none;
  border: 1px solid var(--border);
}
.slider input[type="range"]::-webkit-slider-thumb{
  appearance: none;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent);
  cursor: pointer; border: none;
  box-shadow: 0 2px 6px rgba(0,0,0,.15);
}
.slider input[type="range"]::-moz-range-thumb{
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--accent); border: none;
}

/* Chips / Pills */
.chipbar{ display: flex; flex-wrap: wrap; gap: 8px }
.chip, .pill{
  border: 1px solid var(--border);
  background: #fff;
  color: #3a3f47;
  padding: 6px 10px;
  border-radius: 999px;
  font-size: 13px;
  cursor: pointer;
  transition: transform .02s ease-in-out, border-color .15s, background .15s, box-shadow .15s;
}
.chip:hover{
  transform: translateY(-1px);
  border-color: var(--border-strong);
  box-shadow: 0 4px 14px rgba(0,0,0,.06);
}

/* Mode pills */
.mode{ display: flex; gap: 10px; align-items: center }
.mode label{
  display: inline-flex; gap: 8px; align-items: center;
  padding: 6px 10px; border: 1px solid var(--border); border-radius: 999px;
  background: #fff; cursor: pointer; font-size: 13px;
}
.mode input{ accent-color: var(--accent) }

/* Result panels */
.result{
  display: grid; place-items: center; text-align: center; gap: 10px; padding: 24px; border-radius: 14px;
  background:
    linear-gradient(180deg, rgba(255,28,90,.08), rgba(255,28,90,.03)),
    linear-gradient(180deg, rgba(255,255,255,1), rgba(255,255,255,1));
  border: 1px solid #ffd3df;
}
.big{ font-variant-numeric: tabular-nums; font-size: clamp(34px, 6vw, 56px); line-height: 1.1; font-weight: 800; color: #1b1f25 }
.muted{ color: var(--muted) }
.hint{ color: var(--muted); font-size: 12px; margin-top: .35rem }
.row{ display: flex; flex-wrap: wrap; gap: 8px; color: var(--muted); font-size: 13px }
.pill{ cursor: default } /* pill variant used as info tag */

/* Footer & buttons */
.footer{
  display: flex; flex-wrap: wrap; gap: 8px; justify-content: space-between; align-items: center;
  margin-top: 10px; color: var(--muted); font-size: 12px;
}
.btn{
  border: 1px solid var(--border);
  background: #fff;
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 10px;
  font-weight: 700;
  cursor: pointer;
  transition: border-color .15s, box-shadow .15s, background .15s, color .15s;
}
.btn:hover{
  border-color: var(--border-strong);
  background: #fff7f9;
  color: #b80f3a;
  box-shadow: 0 6px 18px rgba(255, 28, 90, .12);
}

/* Inline code / kbd helpers */
code, .kbd{
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Courier New", monospace;
  background: #fff;
  border: 1px solid var(--border);
  padding: 2px 6px;
  border-radius: 6px;
  color: #383f4a;
}

/* ΔEV preset chips */
.chip.preset { user-select: none; }
.chip.preset:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Active preset state */
.chip.preset.active{
  border-color: var(--accent);
  background: color-mix(in srgb, var(--accent) 12%, #fff);
  box-shadow: 0 0 0 2px color-mix(in srgb, var(--accent) 22%, transparent) inset;
}