/* =========================================================================
 * Tanda Kamera — css/controls.css
 * Footer (tombol shutter & kontrol), catatan kaki, dan animasi bersama.
 * ========================================================================= */

.app-footer {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 26px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(0deg, rgba(15, 23, 42, 0.9), rgba(5, 9, 18, 0.3));
  border-top: 1px solid var(--line);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.ctrl-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  min-width: 62px;
  padding: 8px 10px;
  font-size: 10px;
  font-weight: 600;
  color: #cbd5e1;
  background: rgba(148, 163, 184, 0.12);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 14px;
  cursor: pointer;
  transition: transform 0.15s, background 0.2s, color 0.2s, border-color 0.2s;
}
.ctrl-btn i { font-size: 16px; }
.ctrl-btn:hover { background: rgba(148, 163, 184, 0.2); color: #f8fafc; }
.ctrl-btn:active { transform: scale(0.95); }
.ctrl-btn[disabled] { opacity: 0.45; cursor: not-allowed; }
.ctrl-btn.is-active {
  color: var(--brand-soft);
  border-color: rgba(245, 158, 11, 0.5);
  background: rgba(245, 158, 11, 0.12);
}

/* ------------------------------- Shutter ------------------------------- */

.shutter {
  position: relative;
  width: 74px;
  height: 74px;
  display: grid;
  place-items: center;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  cursor: pointer;
  transition: transform 0.14s ease, background 0.2s;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}
.shutter::after {
  content: "";
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.22);
}
.shutter-core {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: linear-gradient(160deg, #ffffff, #cbd5e1);
  box-shadow: inset 0 -2px 6px rgba(0, 0, 0, 0.15);
  transition: background 0.2s;
}
.shutter:hover .shutter-core { background: linear-gradient(160deg, #ffffff, var(--brand-soft)); }
.shutter:active { transform: scale(0.93); }
.shutter[disabled] { cursor: progress; }
.shutter--busy::after {
  border-color: transparent;
  border-top-color: var(--brand);
  border-right-color: var(--brand);
  animation: spin 0.8s linear infinite;
}
.shutter--busy .shutter-core { background: rgba(148, 163, 184, 0.6); }

/* ------------------------------ Catatan -------------------------------- */

.footnote {
  flex: 0 0 auto;
  margin: 0;
  padding: 0 12px calc(8px + env(safe-area-inset-bottom));
  font-size: 9.5px;
  text-align: center;
  color: #64748b;
  background: rgba(5, 9, 18, 0.6);
}
.footnote i { color: var(--aqua); }

/* ------------------------------ Animasi -------------------------------- */

@keyframes spin { to { transform: rotate(360deg); } }
@keyframes pulse {
  0% { opacity: 0.7; transform: translate(-50%, -50%) scale(1); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(3.2); }
}
@keyframes flash { 0% { opacity: 0.85; } 100% { opacity: 0; } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@keyframes fade-out { to { opacity: 0; transform: translateY(6px); } }
@keyframes pop-in {
  from { opacity: 0; transform: scale(0.96) translateY(8px); }
  to { opacity: 1; transform: none; }
}
@keyframes slide-down {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}
@keyframes slide-up {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}

/* ------------------------------ Responsif ------------------------------ */

@media (max-width: 420px) {
  .brand-text h1 { font-size: 14px; }
  .status-line { font-size: 10.5px; }
  .app-footer { padding-left: 18px; padding-right: 18px; }
  .shutter { width: 68px; height: 68px; }
  .shutter-core { width: 52px; height: 52px; }
  .ctrl-btn { min-width: 56px; }
}
