:root{--bg:#f5f7ff;--card:#fff;--text:#17213b;--muted:#74809a;--pri:#5b6cff;--pri2:#20d4a6;--danger:#ff4d67;--shadow:0 18px 45px rgba(39,53,97,.13);--r:24px}*{box-sizing:border-box}body{margin:0;font-family:-apple-system,BlinkMacSystemFont,'Segoe UI','Noto Sans TC',Arial,sans-serif;background:radial-gradient(circle at top left,#e8fff7,transparent 35%),radial-gradient(circle at top right,#eef0ff,transparent 42%),var(--bg);color:var(--text);min-height:100vh}.login-wrap{min-height:100vh;display:flex;align-items:center;justify-content:center;padding:28px}.login-card{width:100%;max-width:430px;background:rgba(255,255,255,.88);backdrop-filter:blur(16px);border-radius:32px;padding:30px;box-shadow:var(--shadow);border:1px solid rgba(255,255,255,.8)}.brand{display:flex;align-items:center;gap:12px;margin-bottom:22px}.brand img{width:52px;height:52px}.brand h1{font-size:28px;margin:0;letter-spacing:.5px}.field{margin:14px 0}.field label{display:block;font-weight:800;margin-bottom:7px}.input{width:100%;height:48px;border:1px solid #d9e0f2;border-radius:16px;padding:0 14px;font-size:16px;background:#fff}.btn{height:48px;border:0;border-radius:16px;padding:0 18px;font-weight:900;cursor:pointer;display:inline-flex;align-items:center;justify-content:center;gap:9px;text-decoration:none;color:var(--text);transition:.2s transform,.2s box-shadow}.btn:active{transform:scale(.97)}.btn-primary{background:linear-gradient(135deg,var(--pri),#1887ff);color:#fff;box-shadow:0 10px 20px rgba(91,108,255,.26)}.btn-soft{background:#eef2ff;color:#4350d8}.btn-danger{background:var(--danger);color:#fff}.btn-line{background:#fff;border:1px solid #dfe5f2}.btn img{width:22px;height:22px}.full{width:100%}.row{display:flex;gap:10px;align-items:center}.row .btn{flex:1}.msg{padding:12px 14px;border-radius:14px;margin-bottom:14px;font-weight:800}.err{background:#ffe1e5;color:#b70020}.ok{background:#dcfff5;color:#006d51}.hint{color:var(--muted);font-size:13px;margin-top:12px}.app{min-height:100vh;padding:18px 16px 92px}.topbar{display:flex;align-items:center;justify-content:space-between;gap:12px;position:sticky;top:0;z-index:10;background:rgba(245,247,255,.78);backdrop-filter:blur(12px);padding:10px 0}.iconbtn{width:46px;height:46px;border-radius:16px;border:0;background:#fff;box-shadow:0 8px 22px rgba(39,53,97,.08);font-size:22px;font-weight:900}.title{font-size:22px;font-weight:1000}.workspace{margin-top:18px;background:rgba(255,255,255,.72);border:1px solid rgba(255,255,255,.75);border-radius:30px;min-height:calc(100vh - 170px);padding:18px;box-shadow:var(--shadow)}.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(118px,1fr));gap:16px}.folder,.photo-card{background:#fff;border-radius:24px;padding:14px;box-shadow:0 12px 28px rgba(39,53,97,.08);user-select:none;cursor:pointer;position:relative;transition:.18s}.folder:hover,.photo-card:hover{transform:translateY(-2px)}.folder-icon{height:72px;border-radius:18px;background:linear-gradient(135deg,#ffe27a,#ffb44d);position:relative;margin-bottom:9px}.folder-icon:before{content:'';position:absolute;left:10px;top:-9px;width:50px;height:20px;background:#ffd45a;border-radius:12px 12px 4px 4px}.folder-name,.photo-name{font-weight:900;font-size:14px;word-break:break-all}.photo-card img{width:100%;height:100px;object-fit:cover;border-radius:18px;display:block;margin-bottom:8px}.bottom-nav{position:fixed;left:0;right:0;bottom:0;z-index:30;display:flex;justify-content:center;gap:44px;padding:12px 18px calc(12px + env(safe-area-inset-bottom));background:rgba(255,255,255,.76);backdrop-filter:blur(16px);border-top:1px solid rgba(220,226,244,.85)}.navitem{border:0;background:transparent;font-weight:900;color:#53607c;display:flex;flex-direction:column;align-items:center;gap:3px}.navitem svg{width:26px;height:26px}.shutter{width:72px;height:72px;margin-top:-36px;border-radius:50%;background:linear-gradient(135deg,#ff4d7c,#ff9f43);border:7px solid #fff;box-shadow:0 14px 30px rgba(255,77,124,.34)}.drawer-mask{position:fixed;inset:0;background:rgba(7,14,35,.32);z-index:99;opacity:0;pointer-events:none;transition:.25s}.drawer{position:fixed;left:0;top:0;bottom:0;width:min(86vw,360px);background:#fff;border-radius:0 32px 32px 0;z-index:100;transform:translateX(-102%);transition:.32s cubic-bezier(.2,.8,.2,1);box-shadow:20px 0 50px rgba(7,14,35,.2);padding:22px}.drawer.open{transform:none}.drawer-mask.open{opacity:1;pointer-events:auto}.drawer-head{font-size:22px;font-weight:1000;margin-bottom:22px}.menu-btn{width:100%;justify-content:flex-start;margin:8px 0;background:#f4f7ff}.panel{display:none}.panel.active{display:block}.kv{background:#f7f9ff;border-radius:18px;padding:12px;margin:10px 0}.kv b{display:block;margin-bottom:5px}.copyline{display:flex;gap:8px}.copyline input{flex:1}.modal-mask{position:fixed;inset:0;background:rgba(9,16,39,.36);z-index:150;display:none;align-items:center;justify-content:center;padding:18px}.modal{background:#fff;border-radius:28px;padding:20px;width:min(92vw,460px);box-shadow:var(--shadow);animation:pop .18s ease}.modal-mask.show{display:flex}@keyframes pop{from{transform:scale(.92);opacity:.4}to{transform:scale(1);opacity:1}}.context{position:fixed;z-index:180;background:#fff;border-radius:18px;padding:8px;box-shadow:var(--shadow);display:none}.context button{display:block;width:180px;border:0;background:#fff;text-align:left;padding:12px;border-radius:12px;font-weight:900}.context button:hover{background:#f3f6ff}.lightbox{position:fixed;inset:0;background:rgba(7,12,30,.86);z-index:200;display:none;align-items:center;justify-content:center;padding:20px}.lightbox.show{display:flex}.lightbox img{max-width:96vw;max-height:86vh;border-radius:22px;box-shadow:0 20px 60px rgba(0,0,0,.45);animation:zoom .22s ease}@keyframes zoom{from{transform:scale(.75);opacity:.3}to{transform:scale(1);opacity:1}}.tree-folder{padding:12px;border-radius:18px;background:#f5f7ff;margin:8px 0;font-weight:900}.admin-table{width:100%;border-collapse:separate;border-spacing:0 10px}.admin-table td,.admin-table th{background:#fff;padding:12px;text-align:left}.admin-table tr td:first-child,.admin-table tr th:first-child{border-radius:14px 0 0 14px}.admin-table tr td:last-child,.admin-table tr th:last-child{border-radius:0 14px 14px 0}@media(min-width:768px){.app{max-width:980px;margin:auto}.grid{grid-template-columns:repeat(auto-fill,minmax(150px,1fr))}.photo-card img{height:130px}}@media(max-width:520px){.login-card{padding:24px;border-radius:26px}.row{flex-direction:column}.row .btn{width:100%}.workspace{padding:14px}.grid{grid-template-columns:repeat(2,1fr);gap:12px}.bottom-nav{gap:34px}}
.user-admin-table th,.user-admin-table td{white-space:nowrap;vertical-align:middle!important}.pass-pill{display:inline-flex;padding:6px 10px;border-radius:999px;background:#eef5ff;color:#1d4ed8;font-weight:800}.inline-form{display:flex;gap:8px;align-items:center}.mini-input{width:110px;border:1px solid #d7e3f5;border-radius:12px;padding:9px 10px}.btn.small{padding:9px 12px;border-radius:12px;font-size:13px}button:disabled{opacity:.45;cursor:not-allowed}
/* v4 真正相機模式 */
.camera-layer{position:fixed;inset:0;z-index:260;background:#071024;display:none;flex-direction:column;color:#fff}
.camera-layer.show{display:flex;animation:cameraIn .18s ease}
@keyframes cameraIn{from{opacity:.4;transform:scale(.98)}to{opacity:1;transform:scale(1)}}
.camera-top{height:64px;display:flex;align-items:center;justify-content:space-between;padding:12px 18px;background:linear-gradient(180deg,rgba(0,0,0,.38),transparent);font-size:18px}
.cam-close{width:42px;height:42px;border:0;border-radius:50%;background:rgba(255,255,255,.18);color:#fff;font-size:30px;line-height:1}
#cameraVideo{flex:1;width:100%;height:calc(100vh - 150px);object-fit:cover;background:#000}
.camera-bottom{height:86px;padding:10px 18px calc(10px + env(safe-area-inset-bottom));display:flex;align-items:center;justify-content:space-between;background:linear-gradient(0deg,rgba(0,0,0,.46),transparent)}
.big-shutter{width:74px;height:74px;border-radius:50%;border:7px solid #fff;background:linear-gradient(135deg,#ff4d7c,#ff9f43);box-shadow:0 0 0 6px rgba(255,255,255,.2),0 16px 35px rgba(255,77,124,.3)}
.big-shutter:active,.shutter:active{transform:scale(.92)}
.cam-tool{height:44px;min-width:70px;border:0;border-radius:16px;background:rgba(255,255,255,.18);color:#fff;font-weight:900;backdrop-filter:blur(12px)}
.folder.drag-over{outline:4px solid rgba(32,212,166,.45)}

/* v4.1 手機相機視窗與底部拍照列修正：避免被瀏覽器底部列切到 */
:root{--app-vh:100dvh}
.bottom-nav{
  min-height:82px;
  align-items:center;
  padding:8px 18px calc(8px + env(safe-area-inset-bottom));
  gap:40px;
}
.shutter{
  width:64px;
  height:64px;
  margin-top:-18px;
  border-width:6px;
  flex:0 0 auto;
}
.navitem{min-width:58px}
.camera-layer{
  height:var(--app-vh);
  min-height:0;
  overflow:hidden;
}
.camera-top{
  height:56px;
  flex:0 0 56px;
  padding:8px 16px;
}
.cam-close{width:40px;height:40px;font-size:28px}
#cameraVideo{
  flex:1 1 auto;
  min-height:0;
  height:auto;
  max-height:none;
  object-fit:cover;
}
.camera-bottom{
  height:auto;
  min-height:96px;
  flex:0 0 auto;
  padding:8px 18px calc(18px + env(safe-area-inset-bottom));
  align-items:center;
}
.big-shutter{
  width:64px;
  height:64px;
  border-width:6px;
}
.cam-tool{height:42px;min-width:68px}
@media(max-height:680px){
  .camera-top{height:50px;flex-basis:50px}
  .camera-bottom{min-height:86px;padding-bottom:calc(12px + env(safe-area-inset-bottom))}
  .big-shutter{width:58px;height:58px;border-width:5px}
  .cam-tool{height:38px;min-width:62px}
}

/* v5：手機相機底部工具列再上移，避免 Android / iPhone 瀏覽器底部列遮擋 */
.camera-layer{position:fixed;left:0;right:0;top:0;height:var(--app-vh);min-height:0;overflow:hidden;padding-bottom:0;}
#cameraVideo{position:absolute;left:0;right:0;top:56px;bottom:154px;width:100%;height:auto;object-fit:cover;background:#000;}
.camera-bottom{
  position:absolute;
  left:0;
  right:0;
  bottom:64px;
  min-height:86px;
  height:86px;
  padding:8px 22px;
  display:flex;
  align-items:center;
  justify-content:space-between;
  background:linear-gradient(0deg,rgba(0,0,0,.62),rgba(0,0,0,.18),transparent);
  z-index:5;
}
.big-shutter{width:66px;height:66px;border-width:6px;}
@media(max-height:720px){
  #cameraVideo{top:52px;bottom:144px;}
  .camera-bottom{bottom:58px;height:80px;min-height:80px;}
  .big-shutter{width:62px;height:62px;border-width:5px;}
}
@media(max-height:620px){
  #cameraVideo{top:48px;bottom:132px;}
  .camera-bottom{bottom:50px;height:76px;min-height:76px;}
  .big-shutter{width:58px;height:58px;border-width:5px;}
  .cam-tool{height:36px;min-width:58px;font-size:13px;}
}

/* v5：手機照片拖曳進文件夾 */
.photo-card.mobile-dragging{opacity:.38;transform:scale(.96);}
.mobile-drag-ghost{position:fixed;z-index:9999;pointer-events:none;width:96px;height:96px;border-radius:22px;overflow:hidden;box-shadow:0 18px 46px rgba(0,0,0,.32);transform:translate(-50%,-50%) scale(1.03);background:#fff;}
.mobile-drag-ghost img{width:100%;height:100%;object-fit:cover;display:block;}
.folder.drag-over{outline:4px solid rgba(32,212,166,.66);transform:scale(1.03);}

/* v5 真正修正版：手機瀏覽器拍照按鈕再上移，避免 Android Chrome / iPhone Safari 底部工具列遮住 */
body.drag-lock{overflow:hidden!important;touch-action:none!important;overscroll-behavior:none!important;}
.bottom-nav{
  bottom:calc(18px + env(safe-area-inset-bottom))!important;
  padding:8px 18px!important;
  border-radius:28px 28px 0 0!important;
  box-shadow:0 -12px 36px rgba(39,53,97,.16)!important;
}
.bottom-nav .shutter,.shutter{
  width:66px!important;
  height:66px!important;
  margin-top:-44px!important;
}
.camera-layer{
  height:var(--app-vh)!important;
  max-height:var(--app-vh)!important;
  overflow:hidden!important;
}
.camera-top{
  position:absolute!important;
  left:0!important;right:0!important;top:0!important;
  height:58px!important;
  z-index:8!important;
}
#cameraVideo{
  position:absolute!important;
  left:0!important;right:0!important;
  top:58px!important;
  bottom:238px!important;
  width:100%!important;
  height:calc(var(--app-vh) - 296px)!important;
  object-fit:cover!important;
}
.camera-bottom{
  position:absolute!important;
  left:0!important;right:0!important;
  bottom:126px!important;
  height:98px!important;
  min-height:98px!important;
  padding:10px 24px!important;
  z-index:9!important;
  background:linear-gradient(0deg,rgba(7,16,36,.88),rgba(7,16,36,.45),transparent)!important;
}
.big-shutter{
  width:70px!important;
  height:70px!important;
  border-width:7px!important;
}
.photo-card[data-id]{touch-action:none!important;-webkit-user-select:none!important;user-select:none!important;}
.photo-card.mobile-dragging{opacity:.32!important;transform:scale(.94)!important;}
.mobile-drag-ghost{position:fixed!important;z-index:99999!important;pointer-events:none!important;width:106px!important;height:106px!important;border-radius:24px!important;overflow:hidden!important;box-shadow:0 22px 56px rgba(0,0,0,.42)!important;border:4px solid rgba(255,255,255,.92)!important;background:#fff!important;transform:translate(-50%,-50%) scale(1.04)!important;}
.mobile-drag-ghost img{width:100%!important;height:100%!important;object-fit:cover!important;display:block!important;}
.folder.drag-over{outline:5px solid rgba(32,212,166,.82)!important;box-shadow:0 0 0 10px rgba(32,212,166,.18),0 20px 42px rgba(32,212,166,.28)!important;transform:scale(1.04)!important;}
@media(max-height:760px){
  #cameraVideo{top:54px!important;bottom:220px!important;height:calc(var(--app-vh) - 274px)!important;}
  .camera-bottom{bottom:112px!important;height:92px!important;min-height:92px!important;}
  .big-shutter{width:66px!important;height:66px!important;}
}
@media(max-height:650px){
  #cameraVideo{top:50px!important;bottom:202px!important;height:calc(var(--app-vh) - 252px)!important;}
  .camera-bottom{bottom:100px!important;height:86px!important;min-height:86px!important;}
  .big-shutter{width:62px!important;height:62px!important;border-width:6px!important;}
  .cam-tool{height:38px!important;min-width:64px!important;}
}


/* v5.1 依照紅字圖示修正：首頁拍照圓圈下移與首頁/翻轉平行；相機拍照控制列往上移 */
.bottom-nav{
  bottom:calc(16px + env(safe-area-inset-bottom))!important;
  align-items:center!important;
  min-height:86px!important;
  padding:8px 18px!important;
}
.bottom-nav .navitem{
  justify-content:center!important;
}
.bottom-nav .shutter,.shutter{
  width:66px!important;
  height:66px!important;
  margin-top:0!important;
  align-self:center!important;
}
.camera-bottom{
  bottom:210px!important;
  height:98px!important;
  min-height:98px!important;
  padding:10px 24px!important;
  align-items:center!important;
}
#cameraVideo{
  top:58px!important;
  bottom:318px!important;
  height:calc(var(--app-vh) - 376px)!important;
}
@media(max-height:760px){
  .camera-bottom{bottom:176px!important;height:92px!important;min-height:92px!important;}
  #cameraVideo{top:54px!important;bottom:278px!important;height:calc(var(--app-vh) - 332px)!important;}
}
@media(max-height:650px){
  .camera-bottom{bottom:148px!important;height:86px!important;min-height:86px!important;}
  #cameraVideo{top:50px!important;bottom:244px!important;height:calc(var(--app-vh) - 294px)!important;}
}


/* v6 依照 2026-05-10 截圖紅字修正：
   1) 首頁底部三個按鈕同一水平線，拍照圓圈往下，不再凸出切到。
   2) 相機拍照模式底部控制列整欄往上移約一列高度。 */
.bottom-nav{
  position:fixed!important;
  left:0!important;
  right:0!important;
  bottom:calc(18px + env(safe-area-inset-bottom))!important;
  height:92px!important;
  min-height:92px!important;
  padding:10px 18px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:42px!important;
  background:rgba(255,255,255,.84)!important;
  border-radius:28px 28px 0 0!important;
  box-shadow:0 -12px 36px rgba(39,53,97,.16)!important;
}
.bottom-nav .navitem{
  height:70px!important;
  min-width:70px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex-direction:column!important;
  gap:3px!important;
  margin:0!important;
  padding:0!important;
  transform:none!important;
}
.bottom-nav .shutter,
.shutter{
  width:68px!important;
  height:68px!important;
  min-width:68px!important;
  min-height:68px!important;
  margin:0!important;
  align-self:center!important;
  transform:none!important;
  position:relative!important;
  top:0!important;
  flex:0 0 68px!important;
}
.app{padding-bottom:calc(138px + env(safe-area-inset-bottom))!important;}

.camera-layer{
  height:var(--app-vh)!important;
  max-height:var(--app-vh)!important;
  overflow:hidden!important;
}
.camera-top{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:0!important;
  height:58px!important;
  z-index:12!important;
}
.camera-bottom{
  position:absolute!important;
  left:0!important;
  right:0!important;
  bottom:calc(96px + env(safe-area-inset-bottom))!important;
  height:92px!important;
  min-height:92px!important;
  padding:10px 24px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  z-index:12!important;
  background:linear-gradient(0deg,rgba(7,16,36,.92),rgba(7,16,36,.62),transparent)!important;
  border-top:1px solid rgba(255,255,255,.08)!important;
}
#cameraVideo{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:58px!important;
  bottom:calc(200px + env(safe-area-inset-bottom))!important;
  width:100%!important;
  height:auto!important;
  object-fit:cover!important;
  background:#000!important;
}
.big-shutter{
  width:68px!important;
  height:68px!important;
  border-width:7px!important;
  margin:0!important;
  align-self:center!important;
}
.cam-tool{
  height:48px!important;
  min-width:76px!important;
  border-radius:18px!important;
}
@media(max-height:700px){
  .bottom-nav{height:86px!important;min-height:86px!important;gap:36px!important;}
  .bottom-nav .shutter,.shutter{width:64px!important;height:64px!important;min-width:64px!important;min-height:64px!important;flex-basis:64px!important;}
  .bottom-nav .navitem{height:64px!important;min-width:64px!important;}
  .camera-bottom{bottom:calc(86px + env(safe-area-inset-bottom))!important;height:86px!important;min-height:86px!important;}
  #cameraVideo{top:54px!important;bottom:calc(178px + env(safe-area-inset-bottom))!important;}
  .big-shutter{width:62px!important;height:62px!important;border-width:6px!important;}
  .cam-tool{height:42px!important;min-width:68px!important;}
}
@media(max-height:620px){
  .camera-bottom{bottom:calc(78px + env(safe-area-inset-bottom))!important;height:80px!important;min-height:80px!important;}
  #cameraVideo{top:50px!important;bottom:calc(162px + env(safe-area-inset-bottom))!important;}
}

/* ================================
   v7 REAL FIX - bottom nav / camera controls
   2026-05-10
   目的：
   1. 首頁 / 拍照 / 翻轉 完全同一水平線
   2. 拍照圓圈不再凸出
   3. 手機瀏覽器底部列不遮住控制列
   4. 相機拍照視窗底部控制列整欄上移
================================ */
html,body{overscroll-behavior-y:none!important;}
.app{padding-bottom:150px!important;}
.bottom-nav{
  position:fixed!important;
  left:14px!important;
  right:14px!important;
  bottom:calc(28px + env(safe-area-inset-bottom))!important;
  z-index:80!important;
  height:84px!important;
  min-height:84px!important;
  padding:0 22px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  gap:42px!important;
  border-radius:28px!important;
  background:rgba(255,255,255,.88)!important;
  box-shadow:0 16px 38px rgba(29,46,90,.16)!important;
  border:1px solid rgba(225,232,248,.9)!important;
  backdrop-filter:blur(18px)!important;
}
.bottom-nav .navitem{
  width:68px!important;
  min-width:68px!important;
  height:68px!important;
  min-height:68px!important;
  margin:0!important;
  padding:0!important;
  display:flex!important;
  align-items:center!important;
  justify-content:center!important;
  flex-direction:column!important;
  line-height:1.15!important;
  transform:none!important;
  position:relative!important;
  top:0!important;
  flex:0 0 68px!important;
}
.bottom-nav .navitem svg{width:26px!important;height:26px!important;margin:0 0 4px 0!important;}
.bottom-nav .shutter,.shutter{
  width:68px!important;
  height:68px!important;
  min-width:68px!important;
  min-height:68px!important;
  max-width:68px!important;
  max-height:68px!important;
  flex:0 0 68px!important;
  margin:0!important;
  padding:0!important;
  position:relative!important;
  top:0!important;
  transform:none!important;
  align-self:center!important;
  border-radius:50%!important;
  border:7px solid #fff!important;
  display:block!important;
  box-shadow:0 10px 26px rgba(255,77,124,.30)!important;
}
.bottom-nav .shutter:active,.shutter:active{transform:scale(.94)!important;}

.camera-layer{
  position:fixed!important;
  inset:0!important;
  height:var(--app-vh,100dvh)!important;
  min-height:0!important;
  overflow:hidden!important;
  background:#000!important;
}
.camera-layer.show{display:block!important;}
.camera-top{
  position:fixed!important;
  top:0!important;
  left:0!important;
  right:0!important;
  height:70px!important;
  z-index:3!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  padding:12px 18px!important;
  background:linear-gradient(180deg,rgba(4,10,26,.92),rgba(4,10,26,.78))!important;
}
#cameraVideo{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:70px!important;
  bottom:0!important;
  width:100%!important;
  height:calc(var(--app-vh,100dvh) - 70px)!important;
  object-fit:cover!important;
  background:#000!important;
}
.camera-bottom{
  position:fixed!important;
  left:16px!important;
  right:16px!important;
  bottom:calc(118px + env(safe-area-inset-bottom))!important;
  z-index:4!important;
  height:88px!important;
  min-height:88px!important;
  padding:0 18px!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  border-radius:24px!important;
  background:rgba(7,16,36,.78)!important;
  box-shadow:0 18px 38px rgba(0,0,0,.35)!important;
  backdrop-filter:blur(14px)!important;
}
.big-shutter{
  width:68px!important;
  height:68px!important;
  min-width:68px!important;
  min-height:68px!important;
  border-width:7px!important;
  margin:0!important;
  padding:0!important;
  align-self:center!important;
  transform:none!important;
}
.cam-tool{height:48px!important;min-width:74px!important;border-radius:16px!important;}
@media(max-height:720px){
  .bottom-nav{bottom:calc(22px + env(safe-area-inset-bottom))!important;height:78px!important;min-height:78px!important;}
  .bottom-nav .navitem{height:62px!important;min-height:62px!important;flex-basis:62px!important;}
  .bottom-nav .shutter,.shutter{width:62px!important;height:62px!important;min-width:62px!important;min-height:62px!important;flex-basis:62px!important;}
  .camera-bottom{bottom:calc(104px + env(safe-area-inset-bottom))!important;height:82px!important;min-height:82px!important;}
  .big-shutter{width:62px!important;height:62px!important;min-width:62px!important;min-height:62px!important;}
}
@media(max-width:420px){
  .bottom-nav{left:12px!important;right:12px!important;gap:34px!important;}
  .camera-bottom{left:14px!important;right:14px!important;}
}


/* =========================================================
   TAKEPOTO CLOUD v8 REAL UPDATE 2026-05-10
   目的：針對使用者截圖紅字需求真正覆蓋最後樣式
   1) 首頁 / 拍照 / 翻轉 三個按鈕同一水平線
   2) 拍照圓圈往下，不再凸出
   3) 相機拍照視窗底部控制列整欄上移
   ========================================================= */
:root{--takepoto-bottom-lift:34px;--takepoto-camera-lift:128px;}
html,body{overscroll-behavior-y:none!important;}
.app{padding-bottom:calc(132px + env(safe-area-inset-bottom))!important;}
.bottom-nav{
  position:fixed!important;
  left:16px!important;
  right:16px!important;
  bottom:calc(var(--takepoto-bottom-lift) + env(safe-area-inset-bottom))!important;
  height:86px!important;
  min-height:86px!important;
  padding:0 18px!important;
  margin:0!important;
  z-index:999!important;
  display:grid!important;
  grid-template-columns:72px 72px 72px!important;
  align-items:center!important;
  justify-content:center!important;
  column-gap:42px!important;
  border-radius:30px!important;
  background:rgba(255,255,255,.92)!important;
  border:1px solid rgba(226,232,248,.95)!important;
  box-shadow:0 18px 40px rgba(39,53,97,.20)!important;
  backdrop-filter:blur(18px)!important;
  -webkit-backdrop-filter:blur(18px)!important;
}
.bottom-nav .navitem,
.bottom-nav .shutter{
  grid-row:1!important;
  align-self:center!important;
  justify-self:center!important;
  position:static!important;
  top:auto!important;
  bottom:auto!important;
  left:auto!important;
  right:auto!important;
  transform:none!important;
  margin:0!important;
}
.bottom-nav .navitem{
  width:72px!important;
  height:72px!important;
  min-width:72px!important;
  min-height:72px!important;
  padding:0!important;
  border:0!important;
  background:transparent!important;
  display:flex!important;
  flex-direction:column!important;
  align-items:center!important;
  justify-content:center!important;
  gap:4px!important;
  line-height:1.05!important;
  font-size:13px!important;
  font-weight:900!important;
  color:#53607c!important;
}
.bottom-nav .navitem:nth-child(1){grid-column:1!important;}
.bottom-nav .shutter{grid-column:2!important;}
.bottom-nav .navitem:nth-child(3){grid-column:3!important;}
.bottom-nav .navitem svg{width:25px!important;height:25px!important;margin:0!important;display:block!important;}
.bottom-nav .shutter,
.shutter{
  width:68px!important;
  height:68px!important;
  min-width:68px!important;
  min-height:68px!important;
  max-width:68px!important;
  max-height:68px!important;
  border-radius:50%!important;
  border:7px solid #fff!important;
  background:linear-gradient(135deg,#ff4d7c,#ff9f43)!important;
  box-shadow:0 10px 26px rgba(255,77,124,.32)!important;
  display:block!important;
  padding:0!important;
  flex:none!important;
}
.bottom-nav .shutter:active{transform:scale(.94)!important;}

.camera-layer{
  position:fixed!important;
  inset:0!important;
  width:100vw!important;
  height:var(--app-vh,100dvh)!important;
  min-height:0!important;
  overflow:hidden!important;
  background:#000!important;
  z-index:1000!important;
}
.camera-layer.show{display:block!important;}
.camera-top{
  position:absolute!important;
  top:0!important;
  left:0!important;
  right:0!important;
  height:68px!important;
  z-index:5!important;
  display:flex!important;
  align-items:center!important;
  justify-content:space-between!important;
  padding:10px 18px!important;
  background:linear-gradient(180deg,rgba(4,10,26,.96),rgba(4,10,26,.82))!important;
}
#cameraVideo{
  position:absolute!important;
  left:0!important;
  right:0!important;
  top:68px!important;
  bottom:0!important;
  width:100%!important;
  height:calc(var(--app-vh,100dvh) - 68px)!important;
  object-fit:cover!important;
  background:#000!important;
}
.camera-bottom{
  position:absolute!important;
  left:16px!important;
  right:16px!important;
  bottom:calc(var(--takepoto-camera-lift) + env(safe-area-inset-bottom))!important;
  z-index:8!important;
  height:88px!important;
  min-height:88px!important;
  padding:0 18px!important;
  margin:0!important;
  display:grid!important;
  grid-template-columns:84px 72px 84px!important;
  align-items:center!important;
  justify-content:space-between!important;
  border-radius:24px!important;
  background:rgba(7,16,36,.84)!important;
  box-shadow:0 18px 40px rgba(0,0,0,.38)!important;
  backdrop-filter:blur(16px)!important;
  -webkit-backdrop-filter:blur(16px)!important;
}
.camera-bottom .cam-tool{
  height:48px!important;
  min-width:78px!important;
  padding:0 12px!important;
  border-radius:16px!important;
  border:0!important;
  background:rgba(255,255,255,.18)!important;
  color:#fff!important;
  font-weight:900!important;
}
.camera-bottom .big-shutter,
.big-shutter{
  width:68px!important;
  height:68px!important;
  min-width:68px!important;
  min-height:68px!important;
  margin:0!important;
  padding:0!important;
  justify-self:center!important;
  align-self:center!important;
  transform:none!important;
  border:7px solid rgba(255,255,255,.95)!important;
  border-radius:50%!important;
  background:linear-gradient(135deg,#ff4d7c,#ff9f43)!important;
  box-shadow:0 10px 26px rgba(255,77,124,.38)!important;
}
@media(max-height:720px){
  :root{--takepoto-bottom-lift:30px;--takepoto-camera-lift:108px;}
  .bottom-nav{height:80px!important;min-height:80px!important;grid-template-columns:66px 66px 66px!important;column-gap:36px!important;}
  .bottom-nav .navitem{width:66px!important;height:66px!important;min-width:66px!important;min-height:66px!important;}
  .bottom-nav .shutter,.shutter{width:62px!important;height:62px!important;min-width:62px!important;min-height:62px!important;}
  .camera-bottom{height:82px!important;min-height:82px!important;grid-template-columns:80px 66px 80px!important;}
  .camera-bottom .big-shutter,.big-shutter{width:62px!important;height:62px!important;min-width:62px!important;min-height:62px!important;}
}
@media(max-width:420px){
  .bottom-nav{left:12px!important;right:12px!important;column-gap:34px!important;}
  .camera-bottom{left:14px!important;right:14px!important;}
}

/* v8 拖曳強化：確保手機拖照片時文件夾高亮明顯 */
.folder.drag-over{outline:4px solid #35d6ad!important;transform:scale(1.04)!important;background:#ecfff8!important;}
.mobile-drag-ghost{position:fixed!important;width:92px!important;height:92px!important;margin-left:-46px!important;margin-top:-46px!important;z-index:2000!important;pointer-events:none!important;border-radius:22px!important;box-shadow:0 18px 44px rgba(0,0,0,.30)!important;overflow:hidden!important;opacity:.92!important;transform:rotate(-3deg)!important;}
.mobile-drag-ghost img{width:100%!important;height:100%!important;object-fit:cover!important;display:block!important;}
.mobile-dragging{opacity:.35!important;}
.drag-lock{touch-action:none!important;overflow:hidden!important;}


/* =========================================================
   TAKEPOTO CLOUD v8.1 UI FIX
   基底：takepoto_cloud_v8_full.zip
   1. 首頁/拍照/翻轉工具列下移，與文件夾容器下方更接近
   2. 刪除確認框強制最上層，右鍵/長按選單不會蓋住
   3. 刪除確認移除取消鈕；點容器外取消
   4. 確定刪除按鈕加高
   5. 相機拍照視窗底部控制列下移一點
   ========================================================= */
:root{
  --takepoto-bottom-lift:8px!important;
  --takepoto-camera-lift:68px!important;
}
.app{padding-bottom:calc(112px + env(safe-area-inset-bottom))!important;}
.bottom-nav{
  bottom:calc(8px + env(safe-area-inset-bottom))!important;
  height:86px!important;
  min-height:86px!important;
  align-items:center!important;
}
.bottom-nav .navitem,
.bottom-nav .shutter{
  align-self:center!important;
  transform:none!important;
}
.bottom-nav .shutter,
.shutter{
  margin-top:0!important;
  position:relative!important;
  top:0!important;
}
.context{z-index:900!important;}
.modal-mask{
  z-index:5000!important;
  align-items:center!important;
  justify-content:center!important;
}
.modal{
  z-index:5001!important;
  position:relative!important;
}
.delete-confirm h3{font-size:24px!important;margin:0 0 14px!important;line-height:1.28!important;}
.delete-confirm .hint{font-size:16px!important;margin:0 0 18px!important;}
.delete-confirm-btn,
.delete-confirm .btn-danger{
  height:58px!important;
  min-height:58px!important;
  border-radius:18px!important;
  font-size:18px!important;
  width:100%!important;
}
.camera-bottom{
  bottom:calc(68px + env(safe-area-inset-bottom))!important;
}
#cameraVideo{
  bottom:calc(168px + env(safe-area-inset-bottom))!important;
  height:calc(var(--app-vh,100dvh) - 68px - 168px - env(safe-area-inset-bottom))!important;
}
@media(max-height:720px){
  :root{--takepoto-bottom-lift:6px!important;--takepoto-camera-lift:58px!important;}
  .bottom-nav{bottom:calc(6px + env(safe-area-inset-bottom))!important;height:80px!important;min-height:80px!important;}
  .camera-bottom{bottom:calc(58px + env(safe-area-inset-bottom))!important;height:82px!important;min-height:82px!important;}
  #cameraVideo{bottom:calc(150px + env(safe-area-inset-bottom))!important;height:calc(var(--app-vh,100dvh) - 68px - 150px - env(safe-area-inset-bottom))!important;}
}
@media(max-width:420px){
  .bottom-nav{left:12px!important;right:12px!important;bottom:calc(8px + env(safe-area-inset-bottom))!important;}
  .camera-bottom{left:14px!important;right:14px!important;bottom:calc(58px + env(safe-area-inset-bottom))!important;}
}

/* =========================================================
   TAKEPOTO CLOUD v10 CLEAN REBUILD OVERRIDES
   只保留原本 v8.1 介面，重做互動：放大鏡、工具選單、多選。
   ========================================================= */
.title-link{
  border:0!important;background:transparent!important;color:var(--text)!important;
  font:inherit!important;font-size:22px!important;font-weight:1000!important;
  padding:0!important;cursor:pointer!important;text-decoration:none!important;
}
.folder,.photo-card{
  min-height:186px!important;
  display:flex!important;flex-direction:column!important;justify-content:flex-start!important;
  border:3px solid transparent!important;
  overflow:visible!important;
}
.folder.selected,.photo-card.selected{
  border-color:#2288ff!important;
  box-shadow:0 0 0 4px rgba(34,136,255,.18),0 12px 28px rgba(39,53,97,.08)!important;
}
.folder-icon,.thumb-wrap{
  width:100%!important;height:118px!important;border-radius:18px!important;margin-bottom:9px!important;position:relative!important;overflow:hidden!important;
}
.thumb-wrap img,.photo-card img{
  width:100%!important;height:100%!important;object-fit:cover!important;border-radius:18px!important;display:block!important;margin:0!important;
}
.zoom-plus{
  position:absolute!important;right:8px!important;bottom:8px!important;z-index:5!important;
  width:34px!important;height:34px!important;border-radius:50%!important;border:3px solid #fff!important;
  background:linear-gradient(135deg,#4b7cff,#19d3b0)!important;color:#fff!important;
  box-shadow:0 8px 18px rgba(0,0,0,.24)!important;font-size:16px!important;font-weight:1000!important;
  display:flex!important;align-items:center!important;justify-content:center!important;padding:0!important;line-height:1!important;
}
.zoom-plus:active{transform:scale(.92)!important;}
.lightbox{
  cursor:default!important;
  animation:fadeInV10 .18s ease!important;
}
.lightbox img{
  transform-origin:center center!important;
  animation:zoomInV10 .22s cubic-bezier(.2,.9,.2,1)!important;
}
.zoom-minus{
  position:fixed!important;right:24px!important;bottom:calc(24px + env(safe-area-inset-bottom))!important;z-index:205!important;
  width:54px!important;height:54px!important;border-radius:50%!important;border:4px solid #fff!important;
  background:linear-gradient(135deg,#253657,#111827)!important;color:#fff!important;
  font-size:20px!important;font-weight:1000!important;box-shadow:0 12px 34px rgba(0,0,0,.45)!important;
}
@keyframes fadeInV10{from{opacity:0}to{opacity:1}}
@keyframes zoomInV10{from{transform:scale(.72);opacity:.2}to{transform:scale(1);opacity:1}}
.tool-emoji{font-size:27px!important;line-height:1!important;display:block!important;margin-bottom:1px!important;}
.tool-sheet{
  position:fixed!important;left:28px!important;bottom:calc(104px + env(safe-area-inset-bottom))!important;z-index:320!important;
  width:210px!important;padding:10px!important;border-radius:24px!important;background:rgba(255,255,255,.96)!important;
  box-shadow:0 18px 48px rgba(22,32,58,.26)!important;backdrop-filter:blur(18px)!important;-webkit-backdrop-filter:blur(18px)!important;
  display:none!important;transform:translateY(24px) scale(.96)!important;opacity:0!important;
}
.tool-sheet.show{
  display:block!important;animation:toolSheetUpV10 .18s cubic-bezier(.2,.9,.2,1) forwards!important;
}
.tool-sheet button{
  width:100%!important;height:50px!important;border:0!important;border-radius:16px!important;background:#fff!important;color:#111827!important;
  text-align:left!important;padding:0 16px!important;font-size:17px!important;font-weight:1000!important;display:block!important;
}
.tool-sheet button+button{margin-top:6px!important;}
.tool-sheet button:active{background:#eef4ff!important;transform:scale(.98)!important;}
@keyframes toolSheetUpV10{to{transform:translateY(0) scale(1);opacity:1}}
.delete-confirm-btn,.delete-confirm .btn-danger{
  height:60px!important;min-height:60px!important;border-radius:18px!important;font-size:18px!important;
}
.drag-lock{touch-action:none!important;overflow:hidden!important;}
.folder.drag-over{outline:4px solid #35d6ad!important;transform:scale(1.04)!important;background:#ecfff8!important;}
.mobile-drag-ghost{position:fixed!important;width:92px!important;height:92px!important;margin-left:-46px!important;margin-top:-46px!important;z-index:2000!important;pointer-events:none!important;border-radius:22px!important;box-shadow:0 18px 44px rgba(0,0,0,.30)!important;overflow:hidden!important;opacity:.92!important;transform:rotate(-3deg)!important;}
.mobile-drag-ghost img{width:100%!important;height:100%!important;object-fit:cover!important;display:block!important;}
.mobile-dragging{opacity:.35!important;}
@media(min-width:768px){
  .folder-icon,.thumb-wrap{height:138px!important;}
  .folder,.photo-card{min-height:214px!important;}
}
@media(max-width:520px){
  .grid{grid-template-columns:repeat(2,minmax(0,1fr))!important;gap:14px!important;}
  .workspace{overflow:hidden!important;}
  .folder,.photo-card{min-height:176px!important;padding:12px!important;}
  .folder-icon,.thumb-wrap{height:112px!important;}
  .folder-name,.photo-name{font-size:15px!important;line-height:1.25!important;}
  .tool-sheet{left:26px!important;bottom:calc(104px + env(safe-area-inset-bottom))!important;width:206px!important;}
  .zoom-plus{width:32px!important;height:32px!important;right:7px!important;bottom:7px!important;}
}
