:root{
  --miku-height: 160px;
  --miku-bottom: 11px;
  --miku-left: -44px;
  --miku-top-space: 150px;
}

*, *::before, *::after{ box-sizing: border-box; }

html, body{
  height: 100%;
  min-height: 100%;
  background: url("obois.jpg") center / cover no-repeat fixed;
  background-color: #0b4aa0;
}

body{
  margin: 0;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body::before{
  content: "";
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,0.07);
  pointer-events: none;
}

.desktop-icons{
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: auto;
}

.desk-item{
  position: absolute;
  left: var(--x);
  top: var(--y);
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 4px;
  transition: background .12s ease, transform .12s ease, box-shadow .12s ease;
  cursor: url("cursors/hand.svg") 6 2, pointer;
}

.desk-item:hover{
  background: rgba(0,120,215,0.18);
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.7);
}

.desk-item:hover .desk-icon{
  animation: deskWiggle .35s ease-in-out;
  filter: drop-shadow(0 3px 0 rgba(0,0,0,0.18));
}

@keyframes deskWiggle{
  0%{ transform: translateY(0) scale(1); }
  35%{ transform: translateY(-2px) scale(1.03); }
  70%{ transform: translateY(0) scale(1.01); }
  100%{ transform: translateY(0) scale(1); }
}

.desk-icon{
  display: block;
  width: 44px;
  height: 34px;
  position: relative;
}

.desk-icon.folder{
  background: linear-gradient(#f6da8e, #e8b64a);
  border: 1px solid rgba(0,0,0,0.25);
  border-radius: 3px;
  box-shadow: inset 1px 1px 0 rgba(255,255,255,0.75);
}

.desk-icon.folder::before{
  content: "";
  position: absolute;
  left: 4px;
  top: -6px;
  width: 18px;
  height: 10px;
  background: linear-gradient(#fde7b4, #f1c86a);
  border: 1px solid rgba(0,0,0,0.22);
  border-bottom: none;
  border-radius: 3px 3px 0 0;
  box-shadow: inset 1px 1px 0 rgba(255,255,255,0.75);
}

.desk-icon.folder::after{
  content: "";
  position: absolute;
  left: 0;
  top: 8px;
  right: 0;
  bottom: 0;
  border-radius: 2px;
  background: linear-gradient(rgba(255,255,255,0.18), rgba(0,0,0,0.02));
  pointer-events: none;
}

.xp-gifwin{
  position: fixed;
  width: 360px;
  z-index: 9998;
  box-shadow: 0 12px 28px rgba(0,0,0,0.28);
}

.gifwin-body{
  display: grid;
  gap: 10px;
}

.gifwin-img{
  width: 100%;
  height: auto;
  max-height: 220px;
  object-fit: contain;
  border: 1px solid rgba(0,0,0,0.25);
  background: rgba(255,255,255,0.65);
  box-shadow: inset 1px 1px 0 rgba(255,255,255,0.9);
  padding: 6px;
}

.gifwin-actions{
  display: flex;
  justify-content: flex-end;
}

.xp-note{
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 320px;
  z-index: 9999;
  box-shadow: 0 10px 25px rgba(0,0,0,0.25);
}

.xp-note .window-body{ font-size: 12px; }

.note-actions{
  display: flex;
  justify-content: flex-end;
  margin-top: 10px;
}

.wrap{
  position: relative;
  z-index: 10;
  max-width: 900px;
  margin: 18px auto;
  padding: var(--miku-top-space) 12px 24px;
}

.hero .window-body{
  display: grid;
  gap: 12px;
}

.hero-titlebar{
  position: relative;
  overflow: visible;
}

.hero-titlebar .title-bar-text{
  position: relative;
  z-index: 1;
}

.hero-titlebar .title-bar-controls{
  position: relative;
  z-index: 3;
}

.title-miku{
  position: absolute;
  left: var(--miku-left);
  bottom: var(--miku-bottom);
  height: var(--miku-height);
  width: auto;
  transform: scaleX(-1);
  pointer-events: none;
  user-select: none;
  z-index: 2;
  filter: drop-shadow(0 3px 0 rgba(0,0,0,0.18));
}

.app-menubar{
  display: flex;
  gap: 18px;
  align-items: center;
  padding: 4px 8px;
  background: #efefe7;
  border: 1px solid rgba(0,0,0,0.25);
  box-shadow: inset 1px 1px 0 #fff;
  font-size: 12px;
  margin-top: 2px;
}

.app-menuitem{
  cursor: default;
  user-select: none;
  text-decoration: underline;
  padding: 1px 2px;
}

.app-menuitem:hover{ background: rgba(0,0,0,0.08); }

.divider{ height: 1px; background: rgba(0,0,0,0.25); }

html, body{ cursor: url("cursors/arrow.svg") 1 1, auto; }

a, button, [role="button"], input[type="submit"], input[type="button"]{
  cursor: url("cursors/hand.svg") 6 2, pointer;
}

input[type="text"], input[type="email"], input[type="password"], textarea{ cursor: text; }

.products{
  border: 1px solid rgba(0,0,0,0.25);
  background: rgba(255,255,255,0.45);
  padding: 10px;
  display: grid;
  gap: 10px;
}

.products-head{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(0,0,0,0.15);
}

.products-title{
  font-weight: 900;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: .8px;
}

.product-grid{
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 760px){
  .product-grid{ grid-template-columns: 1fr; }
}

.xp-card{
  border: 1px solid rgba(0,0,0,0.25);
  background: rgba(245,245,236,0.96);
  box-shadow: inset 1px 1px 0 rgba(255,255,255,0.9);
  overflow: hidden;
}

.xp-cardbar{
  padding: 6px 8px;
  background: linear-gradient(#0a67d8, #0a5fc8);
  color: #fff;
  font-weight: 700;
  text-transform: lowercase;
  letter-spacing: .2px;
}

.xp-cardbody{
  padding: 10px;
  display: grid;
  gap: 10px;
}

.product-mainframe{
  border: 1px solid rgba(0,0,0,0.25);
  background: rgba(255,255,255,0.65);
  padding: 10px;
  box-shadow: inset 1px 1px 0 rgba(255,255,255,0.9);
  overflow: hidden;
}

.product-main{
  display: block;
  width: 100%;
  height: auto;
  max-height: 280px;
  object-fit: contain;
}

.product-thumbs{
  display: flex;
  gap: 6px;
  align-items: center;
  flex-wrap: wrap;
}

.thumb{
  border: 1px solid rgba(0,0,0,0.25);
  background: rgba(255,255,255,0.65);
  padding: 3px;
  width: 56px;
  height: 44px;
  display: grid;
  place-items: center;
  box-shadow: inset 1px 1px 0 rgba(255,255,255,0.9);
  overflow: hidden;
}

.thumb img{
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.thumb.is-active{
  outline: none;
  box-shadow: inset 0 0 0 2px rgba(0,0,0,0.65), inset 1px 1px 0 rgba(255,255,255,0.9);
}

.thumb:active{ transform: translateY(1px); }

.stamps-section{
  border: none;
  background: transparent;
  padding: 0;
}

.stamps-grid{
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: flex-start;
  justify-content: center;
}

.stamp{
  display: block;
  width: auto;
  height: auto;
  max-width: 120px;
  max-height: 80px;
  object-fit: contain;
  border: none;
  background: transparent;
  padding: 0;
}
