/* SeaZal: same palette as ui/theme/Color.kt. Phone layout like the app, wider layout on desktop. */
:root{
  --ocean:#1E88C7; --deep:#07395C; --aqua:#5CE1E6; --aqua-soft:#DDF3F8;
  --coral:#FF7A59; --coral-soft:#FFE6DE; --green:#2E9B5F; --green-soft:#DDF3E6;
  --amber:#D99100; --amber-soft:#FFF1CC; --red:#D93B3B; --red-soft:#FBE0E0;
  --gold:#F5B301; --ink:#14202B; --muted:#6B7885; --line:#DDE3E8; --bg:#F5F8FA;
  --white:#fff; --indigo-soft:#E3E9F4; --grey-soft:#EEF2F5;
  --grad:linear-gradient(var(--ocean),var(--deep));
  color-scheme:light;
}
*{box-sizing:border-box;margin:0;padding:0}
html,body{min-height:100%}
body{background:var(--bg);color:var(--ink);font:400 16px/1.45 Roboto,system-ui,-apple-system,"Segoe UI",sans-serif;-webkit-tap-highlight-color:transparent}
img{max-width:100%;display:block}
button,input,textarea{font:inherit;color:inherit}
button{background:none;border:0;cursor:pointer}
:focus-visible{outline:3px solid var(--coral);outline-offset:2px}
[hidden]{display:none!important}
svg.i{width:24px;height:24px;fill:currentColor;flex:none}
.grow{flex:1;min-width:0}
.row{display:flex;align-items:center;gap:12px}
.stack{display:flex;flex-direction:column;gap:12px}
.ellipsis{white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.muted{color:var(--muted)} .small{font-size:13px} .tiny{font-size:12px} .link{color:var(--ocean)}
.center{text-align:center} .bold{font-weight:700} .semi{font-weight:600}
.price{color:var(--ocean);font-weight:600}
h1{font-size:26px;line-height:1.25} h2{font-size:18px} h3{font-size:16px;overflow-wrap:anywhere}
.mt4{margin-top:4px}.mt8{margin-top:8px}.mt12{margin-top:12px}.mt16{margin-top:16px}.mt24{margin-top:24px}.mt32{margin-top:32px}

/* Buttons and inputs */
.btn{display:flex;align-items:center;justify-content:center;gap:8px;width:100%;min-height:52px;padding:10px 16px;border-radius:14px;background:var(--ocean);color:var(--white);font-weight:600}
.btn:hover{filter:brightness(1.06)}
.btn.deep{background:var(--deep)}
.btn.white{background:var(--white);color:var(--deep)}
.btn.out{background:transparent;border:1.5px solid currentColor;color:var(--ocean);min-height:48px;font-size:15px}
.btn.out.white{color:var(--white)}
.btn.out.red{color:var(--red)} .btn.out.green{color:var(--green)} .btn.out.line{border-color:var(--line)}
.textbtn{color:var(--ocean);font-weight:600;padding:8px;border-radius:8px}
.textbtn.red{color:var(--red)} .textbtn.grey{color:var(--muted)}
.iconbtn{width:44px;height:44px;border-radius:50%;display:inline-grid;place-items:center;position:relative;flex:none}
.iconbtn:hover{background:rgba(30,136,199,.1)}
.iconbtn.solid{background:rgba(255,255,255,.92);color:var(--ink)}
.field{position:relative;display:flex;align-items:center;gap:10px;background:var(--white);border:1px solid var(--line);border-radius:14px;padding:0 14px;width:100%;text-align:left}
.field:focus-within{border-color:var(--ocean);box-shadow:0 0 0 1px var(--ocean)}
.field.err{border-color:var(--red)}
.field>svg{color:var(--muted)} .field:focus-within>svg{color:var(--ocean)}
.field label{flex:1;min-width:0;display:flex;flex-direction:column;padding:7px 0}
.field label span{font-size:12px;color:var(--muted)}
.field input,.field textarea{border:0;outline:0;background:transparent;width:100%;font-size:16px;resize:vertical}
.field ::placeholder{color:#9aa6b1}
.error{color:var(--red);font-size:13px;width:100%;text-align:left;margin-top:10px}

/* Cards, chips, avatars */
.card{display:block;width:100%;text-align:left;background:var(--white);border:1px solid var(--line);border-radius:16px;padding:14px;box-shadow:0 1px 2px rgba(20,32,43,.06)}
.card.row{display:flex}
button.card:hover,a.card:hover,.card.tap:hover{border-color:var(--ocean)}
.card.tap{cursor:pointer}
.tapline{display:flex;align-items:center;gap:12px;width:100%;text-align:left;padding:6px 0;border-radius:10px}
.chip{display:inline-block;font-size:12px;font-weight:600;padding:3px 10px;border-radius:50px}
.chip.in,.chip.green{background:var(--green-soft);color:var(--green)}
.chip.low{background:var(--amber-soft);color:var(--amber)}
.chip.oos{background:var(--red-soft);color:var(--red)}
.chip.admin{background:var(--coral-soft);color:var(--red)}
.chip.vendor{background:var(--aqua-soft);color:var(--ocean)}
.chip.tourist{background:#EAEFF3;color:var(--muted)}
.picker{display:grid;grid-template-columns:repeat(3,1fr);gap:8px}
.picker button{min-height:44px;border-radius:12px;background:var(--grey-soft);color:var(--muted);font-size:12px;font-weight:500;padding:8px 4px}
.picker button[aria-pressed=true]{font-weight:700}
.picker button.in[aria-pressed=true]{background:var(--green-soft);color:var(--green)}
.picker button.low[aria-pressed=true]{background:var(--amber-soft);color:var(--amber)}
.picker button.oos[aria-pressed=true]{background:var(--red-soft);color:var(--red)}
.avatar{border-radius:50%;display:grid;place-items:center;background:var(--aqua-soft);color:var(--ocean);font-weight:700;object-fit:cover;flex:none;overflow:hidden}
.avatar.light{background:rgba(255,255,255,.2);color:var(--white)}
.stars{display:flex;color:var(--line)} .stars svg{width:16px;height:16px} .stars .on{color:var(--gold)}
.tilebox{width:44px;height:44px;border-radius:12px;display:grid;place-items:center;flex:none}
.t-blue{background:var(--aqua-soft);color:var(--ocean)} .t-coral{background:var(--coral-soft);color:var(--coral)}
.t-brown{background:var(--coral-soft);color:#B5502F} .t-deep{background:var(--indigo-soft);color:var(--deep)}
.t-green{background:var(--green-soft);color:var(--green)} .t-amber{background:var(--amber-soft);color:var(--amber)}
.t-red{background:var(--red-soft);color:var(--red)}
.empty{text-align:center;padding:32px;display:flex;flex-direction:column;align-items:center;gap:8px;grid-column:1/-1}
.empty .circle{width:80px;height:80px;border-radius:50%;display:grid;place-items:center;background:var(--aqua-soft);color:var(--ocean);margin-bottom:8px}
.empty .circle svg{width:38px;height:38px}
.photo{object-fit:cover;background:var(--aqua-soft);display:grid;place-items:center;font-size:28px;overflow:hidden;flex:none}
.thumb{width:76px;height:76px;border-radius:12px} .thumb.s{width:64px;height:64px}
.list{display:grid;gap:12px;grid-template-columns:repeat(auto-fill,minmax(min(100%,320px),1fr));align-items:start}

/* Welcome and auth */
.welcome{min-height:100vh;min-height:100dvh;display:flex;justify-content:center;background:linear-gradient(rgba(7,57,92,.7),rgba(7,57,92,.25),rgba(7,57,92,.95)),url(../images/login_bg.jpg) center/cover fixed;color:var(--white)}
.welcome>div{width:100%;max-width:440px;display:flex;flex-direction:column;align-items:center;padding:56px 28px 24px;gap:12px}
.welcome h1{font-size:36px}
.logo{border-radius:50%;object-fit:cover;background:var(--white)}
.points{width:100%;margin:auto 0 20px;padding-top:40px;display:flex;flex-direction:column;gap:10px;font-size:15px}
.points svg{color:var(--aqua);width:22px;height:22px}
.auth{position:relative;min-height:100vh;min-height:100dvh;display:flex;align-items:center;justify-content:center;padding:20px 16px;isolation:isolate;overflow:hidden}
.auth::before{content:"";position:fixed;inset:-30px;background:url(../images/login_bg.jpg) center/cover;filter:blur(10px);z-index:-2}
.auth::after{content:"";position:fixed;inset:0;background:linear-gradient(rgba(11,61,107,.6),rgba(6,40,71,.8));z-index:-1}
.panel{width:100%;max-width:440px;background:rgba(255,255,255,.97);border-radius:24px;padding:24px;display:flex;flex-direction:column;align-items:center;text-align:center}
.panel .field+.field{margin-top:14px}
.plain{max-width:560px;margin:0 auto;padding:12px 20px 32px;min-height:100vh}
.typeicon{width:56px;height:56px;border-radius:16px;display:grid;place-items:center;flex:none}
.pickphoto{width:96px;height:96px;border-radius:50%;background:var(--aqua-soft);display:grid;place-items:center;cursor:pointer;overflow:hidden;color:var(--ocean);position:relative}
.pickphoto.wide{width:100%;height:120px;border-radius:16px}
.pickphoto.tall{width:100%;height:170px;border-radius:18px;text-align:center}
.pickphoto img{width:100%;height:100%;object-fit:cover}
.filein{position:absolute;opacity:0;width:1px;height:1px}
label:focus-within>.pickphoto,.pickphoto:focus-within{outline:3px solid var(--coral)}

/* Tourist shell */
.page{max-width:1040px;margin:0 auto;padding:16px 20px 24px;width:100%}
.page.narrow{max-width:680px}
.tourist-shell{padding-bottom:84px}
.tabs{position:fixed;bottom:0;left:0;right:0;background:var(--white);border-top:1px solid var(--line);display:flex;justify-content:center;padding:8px 0 calc(8px + env(safe-area-inset-bottom,0px));z-index:5}
.tabs a{flex:1;max-width:160px;display:flex;flex-direction:column;align-items:center;gap:2px;font-size:12px;color:var(--muted)}
.tabs a span{padding:3px 18px;border-radius:50px;display:grid}
.tabs a[aria-current=page]{color:var(--ocean);font-weight:600}
.tabs a[aria-current=page] span{background:var(--aqua-soft)}
.hero{background:var(--grad);color:var(--white);border-radius:0 0 28px 28px;padding:16px 0 20px}
.hero .page{padding-block:0}
.search-entry{display:flex;align-items:center;gap:10px;width:100%;background:var(--white);color:var(--muted);border-radius:16px;padding:14px 16px;font-size:14px;margin-top:16px;text-align:left}
.dot{position:absolute;top:10px;right:10px;width:9px;height:9px;border-radius:50%;background:var(--coral)}
.banner{height:150px;border-radius:20px;background:linear-gradient(transparent,rgba(7,57,92,.8)),url(../images/login_bg.jpg) center 70%/cover;color:var(--white);display:flex;flex-direction:column;justify-content:flex-end;padding:16px}
.cats{display:flex;justify-content:space-between;max-width:520px;margin:24px auto 0}
.cats a{display:flex;flex-direction:column;align-items:center;gap:6px;font-size:12px;font-weight:500;padding:4px;border-radius:16px}
.cats i{width:64px;height:64px;border-radius:20px;display:grid;place-items:center;font-style:normal;font-size:28px}
.cats svg{width:28px;height:28px}
.popular{display:flex;gap:12px;overflow-x:auto;padding:2px 2px 10px}
.product{width:160px;flex:none;cursor:pointer;position:relative}
@media(min-width:760px){.popular{display:grid;grid-template-columns:repeat(auto-fill,minmax(200px,1fr));overflow:visible}.product{width:auto}.product .photo{height:150px!important}.banner{height:220px}}
.product .photo{width:100%;height:105px;border-radius:12px;margin-bottom:8px}
.fav{position:absolute;color:var(--white);filter:drop-shadow(0 0 3px rgba(0,0,0,.65))}
.fav[aria-pressed=true]{color:var(--coral)}
.product .fav{top:18px;right:18px;width:34px;height:34px}
.cover{position:relative}
.cover .photo{width:100%;height:300px}
@media(min-width:760px){.cover{max-width:680px;margin:16px auto 0}.cover .photo{height:420px;border-radius:20px}}
.cover .back{position:absolute;top:12px;left:12px}
.cover .fav{top:12px;right:12px}
.shopcover{position:relative;height:215px;max-width:680px;margin:0 auto}
.shopcover>.banner-img{width:100%;height:160px;object-fit:cover;background:var(--grad)}
.shopcover .back{position:absolute;top:12px;left:12px}
.shopcover .face{position:absolute;left:20px;bottom:0;width:104px;height:104px;border-radius:50%;background:var(--white);display:grid;place-items:center;color:var(--deep)}
.switchrow{display:flex;align-items:center;gap:12px;cursor:pointer}
.switch{appearance:none;width:48px;height:28px;border-radius:50px;background:#c5ced6;position:relative;cursor:pointer;flex:none;transition:background .2s}
.switch::after{content:"";position:absolute;width:22px;height:22px;border-radius:50%;background:var(--white);top:3px;left:3px;transition:transform .2s}
.switch:checked{background:var(--ocean)} .switch:checked::after{transform:translateX(20px)}
.gradcard{background:var(--grad);color:var(--white);border-radius:20px;padding:20px}
.menurow{display:flex;align-items:center;gap:16px;width:100%;padding:10px 4px;border-radius:14px;font-weight:600;text-align:left}
.menurow:hover{background:var(--white)}
.avwrap{position:relative;flex:none;cursor:pointer}
.editdot{position:absolute;right:0;bottom:0;width:28px;height:28px;border-radius:50%;background:var(--ocean);border:2px solid var(--white);display:grid;place-items:center;color:var(--white)}
.editdot svg{width:14px;height:14px}

/* Admin and vendor shell with drawer */
.topbar{position:sticky;top:env(safe-area-inset-top,0px);background:var(--bg);display:flex;align-items:center;gap:4px;padding:6px 8px;z-index:4}
.topbar h1{font-size:20px}
.drawer{position:fixed;top:0;bottom:0;left:0;width:min(300px,85vw);background:var(--white);z-index:8;display:flex;flex-direction:column;transform:translateX(-101%);transition:transform .25s;visibility:hidden}
.drawer.open{transform:none;visibility:visible;box-shadow:0 0 40px rgba(0,0,0,.25)}
.drawer header{background:var(--grad);color:var(--white);padding:24px}
.drawer nav{padding:12px;display:flex;flex-direction:column;gap:2px;flex:1;overflow:auto}
.navitem{display:flex;align-items:center;gap:12px;padding:14px 16px;border-radius:50px;font-size:14px;font-weight:500;text-align:left;width:100%}
.navitem svg{color:var(--muted)}
.navitem[aria-current=page]{background:var(--aqua-soft);color:var(--ocean)} .navitem[aria-current=page] svg{color:var(--ocean)}
.navitem.logout,.navitem.logout svg{color:var(--red)}
.drawer footer{border-top:1px solid var(--line);padding:8px 12px calc(8px + env(safe-area-inset-bottom,0px))}
.badge{background:var(--red);color:var(--white);font-size:11px;font-weight:700;border-radius:20px;min-width:18px;padding:0 5px;line-height:18px;text-align:center}
.iconbtn .badge{position:absolute;top:3px;right:2px}
.scrim{position:fixed;inset:0;background:rgba(0,0,0,.4);z-index:7}
@media(min-width:900px){
  .shell{padding-left:280px}
  .drawer{transform:none;visibility:visible;width:280px;border-right:1px solid var(--line);box-shadow:none!important}
  .scrim,.menu-btn{display:none!important}
  .topbar{padding:14px 20px}
}
.stats{display:grid;gap:12px;grid-template-columns:repeat(2,1fr)}
.stats.three{grid-template-columns:repeat(3,1fr);gap:10px}
@media(min-width:760px){.stats{grid-template-columns:repeat(4,1fr)}.stats.three{grid-template-columns:repeat(3,1fr)}}
.stat .tilebox{width:36px;height:36px;border-radius:10px;margin-bottom:10px}
.stat .tilebox svg{width:20px;height:20px}
.stat b{display:block;font-size:26px}
.bar{flex:1;height:8px;border-radius:50px;background:var(--line);overflow:hidden}
.bar i{display:block;height:100%;background:var(--gold)}

/* Dialog, toast, intro */
.overlay{position:fixed;inset:0;background:rgba(0,0,0,.45);z-index:20;display:grid;place-items:center;padding:24px}
.dialog{background:var(--white);border-radius:24px;padding:24px;width:100%;max-width:420px;max-height:100%;overflow:auto}
.dialog .actions{display:flex;justify-content:flex-end;gap:8px;margin-top:20px;flex-wrap:wrap}
.dialog .actions a{text-decoration:none}
.locpic{width:100%;height:220px;border-radius:14px;background:var(--aqua-soft);display:grid;place-items:center;color:var(--coral);overflow:hidden}
.locpic img{width:100%;height:100%;object-fit:cover}.locpic svg{width:48px;height:48px}
#toast{position:fixed;left:50%;bottom:calc(96px + env(safe-area-inset-bottom,0px));transform:translateX(-50%);background:#26313b;color:var(--white);padding:12px 18px;border-radius:24px;font-size:14px;z-index:30;width:max-content;max-width:calc(100vw - 32px);text-align:center}

.slide-f{animation:slidef .3s ease} .slide-b{animation:slideb .3s ease}
@keyframes slidef{from{opacity:0;transform:translateX(10%)}}
@keyframes slideb{from{opacity:0;transform:translateX(-10%)}}
.stagger>*{animation:up .45s cubic-bezier(.4,0,.2,1) backwards;animation-delay:calc(var(--n,8)*70ms)}
@keyframes up{from{opacity:0;transform:translateY(48px)}}

#intro{position:fixed;inset:0;z-index:50;background:var(--grad);background:linear-gradient(var(--deep),var(--ocean));display:grid;place-items:center;overflow:hidden;animation:introOut .45s 2.9s forwards}
@keyframes introOut{to{opacity:0;visibility:hidden}}
.water{position:absolute;left:0;bottom:0;width:100%;height:calc(24% + 30px);animation:rise 1.4s cubic-bezier(.4,0,.2,1) backwards}
@keyframes rise{from{transform:translateY(100%)}}
.water svg{position:absolute;left:0;top:0;width:200%;height:100%;animation:wave 2.2s linear infinite}
@keyframes wave{to{transform:translateX(-33.333%)}}
.intro-mid{position:relative;display:flex;flex-direction:column;align-items:center;gap:64px}
.intro-logo{position:relative;width:min(240px,60vw);aspect-ratio:1;animation:bob 1.6s ease-in-out infinite alternate}
@keyframes bob{from{translate:0 -6px}to{translate:0 6px}}
.intro-logo .pop{position:relative;width:100%;height:100%;border-radius:50%;overflow:hidden;background:var(--white);animation:pop .9s .2s cubic-bezier(.3,1.7,.5,1) backwards}
.intro-logo img{width:100%;height:100%;object-fit:cover;transform:scale(1.07)}
@keyframes pop{from{opacity:0;transform:scale(.3) rotate(-12deg)}}
.ring{position:absolute;inset:0;border:3px solid rgba(255,255,255,.4);border-radius:50%;opacity:0;animation:ripple 1.2s ease-out forwards}
@keyframes ripple{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(1.7)}}
.tagline{color:var(--white);font-weight:500;letter-spacing:.5px;animation:tag .5s 1.2s backwards;padding:0 16px;text-align:center}
@keyframes tag{from{opacity:0;transform:translateY(24px)}}
@media(prefers-reduced-motion:reduce){*,*::before,*::after{animation-duration:.01ms!important;animation-delay:0s!important;transition:none!important}#intro{display:none}}

/* PHP version: links, forms and native dialogs */
a{color:inherit;text-decoration:none}
a.textbtn{color:var(--ocean);display:inline-block}
a.textbtn.grey{color:var(--muted)}
a.btn{color:var(--white)} a.btn.white{color:var(--deep)} a.btn.out{color:var(--ocean)} a.btn.out.white{color:var(--white)}
form.inline{display:contents}
.row>form{flex:1} .row>form.fit{flex:none}
.product>a{display:block}
.product form{position:absolute;top:18px;right:18px} .product .fav{position:static;width:34px;height:34px}
.cover>form{position:absolute;top:12px;right:12px} .cover>form .fav{position:static}
.card .grow>a{display:block}
dialog.dialog{margin:auto;border:0;max-height:90vh;color:var(--ink)}
dialog::backdrop{background:rgba(0,0,0,.45)}
.picker label{display:grid}
.picker input{position:absolute;opacity:0;width:1px;height:1px}
.picker span{display:grid;place-items:center;min-height:44px;border-radius:12px;background:var(--grey-soft);color:var(--muted);font-size:12px;font-weight:500;padding:8px 4px;text-align:center;cursor:pointer}
.picker input:checked+span{font-weight:700}
.picker input.in:checked+span{background:var(--green-soft);color:var(--green)}
.picker input.low:checked+span{background:var(--amber-soft);color:var(--amber)}
.picker input.oos:checked+span{background:var(--red-soft);color:var(--red)}
.picker input:focus-visible+span{outline:3px solid var(--coral)}
.rate{display:flex;flex-direction:row-reverse;justify-content:flex-end}
.rate input{position:absolute;opacity:0;width:1px;height:1px}
.rate label{width:44px;height:44px;display:grid;place-items:center;cursor:pointer;color:var(--muted)}
.rate label svg{width:32px;height:32px}
.rate input:checked~label,.rate label:hover,.rate label:hover~label{color:var(--gold)}
.rate input:focus-visible+label{outline:3px solid var(--coral);border-radius:50%}
