:root {
  overflow-x: hidden;
  --bg: #0a0a0a;
  --panel: #0f1424;
  --muted: #8892a6;
  --text: #e6edf3;
  --accent: #2c2c2c;
  --accent-strong: #1f1f1f;
  --ok: #22c55e;
  --warn: #f59e0b;
  --danger: #ef4444;
  --ring: 0 0 0 2px rgba(34, 34, 34, 0.3);
  --radius: 10px;
  --shadow: 0 10px 30px rgba(10, 10, 10, 0.35);
}

* {
  box-sizing: border-box;
}

html,
body {
  height: 100%;
  scrollbar-width: none;
}

body {
  margin: 0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial, Apple Color Emoji, Segoe UI Emoji;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body::-webkit-scrollbar {
  display: none;
}

#customScrollbar {
  position: fixed;
  right: 7px;
  top: 12px;
  width: 5px;
  height: calc(100vh - 24px);
  z-index: 99999;
  pointer-events: none;
}

#customThumb {
  width: 100%;
  background: rgba(255,255,255,.12);
  border-radius: 999px;
  backdrop-filter: blur(8px);
}

#customThumb {
    cursor: grab;
}

#customThumb:active {
    cursor: grabbing;
}

a {
  color: var(--accent-strong);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

img {
  max-width: 100%;
  height: auto;
  border-radius: 12px;
}

.hide {
  display: none;
}

.container {
  max-width: 100%;
  margin: 0 auto;
  padding: 20px 20px 28px;
}

header {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: var(--bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  position: sticky;
  top: 16px;
  backdrop-filter: blur(8px);
  z-index: 10;
}

header img {
  width: 90px;
  height: 100%;
  border-radius: 14px;
  object-fit: cover;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.title {
  flex: 1;
}

.title h1 {
  margin: 0;
  font-size: 20px;
  letter-spacing: 0.3px;
}

.sub {
  font-size: 13px;
  color: var(--muted);
}

.badges {
  display: flex;
  gap: 0 8px;
  flex-wrap: wrap;
  padding-top: 5px;
}

.badge {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.03);
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.badgebtn {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.03);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text);
}

.badgebtn:hover {
  box-shadow: var(--ring);
  text-decoration: none;
}

.badgebtn:active {
  background: var(--accent-strong);
}

.Filterbadgebtn {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.03);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text);
}

.Filterbadgebtn:hover {
  box-shadow: var(--ring);
  text-decoration: none;
}

.Filterbadgebtn:active {
  background: var(--accent-strong);
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  display: inline-block;
  background: var(--ok);
}

nav {
  display: flex;
  gap: 8px;
}

.btn {
  font-size: 12px;
  padding: 6px 10px;
  border-radius: 5px;
  border: 1px solid rgba(255, 255, 255, 0.09);
  background: rgba(255, 255, 255, 0.03);
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  color: var(--text);
}

.btn:hover {
  box-shadow: var(--ring);
  text-decoration: none;
}

.filter-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
}

main {
  grid-template-columns: 1fr;
  gap: 18px;
  margin-top: 18px;
}

section {
  padding-left: 18px;
  padding-right: 18px;
  padding-bottom: 18px;
  padding-top: 10px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: var(--bg);
  border-radius: var(--radius);
}

section h2 {
  margin: 4px 0 6px;
  font-size: 18px;
}

.muted {
  color: var(--muted);
}

.smalltext {
  color: var(--muted);
  font-size: 12px;
}

.grid {
  display: grid;
  gap: 14px;
}

.stack {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.chip {
  padding: 8px 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.03);
  font-size: 14px;
}

.card {
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 7px;
  background: rgba(255, 255, 255, 0.03);
}

.card header {
  position: relative;
  top: auto;
  box-shadow: none;
  background: transparent;
  border: none;
  padding: 0;
}

.card h3 {
  margin: 0;
  font-size: 15px;
}

.card p {
  font-size: 14px;
  margin: 8px 0 0;
}

.reviewcards {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
}

.cards {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
}

.cards img {
  opacity: 1;
  transform: scale(1);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.cards img.hide {
  opacity: 0;
  transform: scale(0.95);
  pointer-events: none;
}

.hoverimage {
  width: 100%;
  transition: transform 0.3s ease;
  cursor: pointer;
}

.hoverimage:hover {
  transform: scale(1.025);
}

video.hoverimage {
  object-fit: cover;
}

#hoverTooltip {
    position: fixed;
    left: 0;
    top: 0;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: rgba(10,10,10,.95);
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 6px;
    color: var(--text);
    font-size: 12px;
    backdrop-filter: blur(8px);
    pointer-events: none;
    z-index: 999999;
    opacity: 0;
    transform: translate(12px,-22px);
    transition: opacity .15s ease;
}

.portfolio-item {
  position: relative;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  overflow: hidden;
  padding: 8px;
  transition: 0.2s ease;
}

.portfolio-id {
    position: absolute;
    top: 8px;
    left: 8px;
    z-index: 10;
    background: rgba(0,0,0,.75);
    color: #fff;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    pointer-events: none;
    backdrop-filter: blur(4px);
}

.portfolio-item:hover {
  border-color: rgba(255, 255, 255, 0.15);
}

.portfolio-item .hoverimage {
  width: 100%;
  display: block;
  border-radius: 6px;
}

.overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.overlay.active {
  display: flex;
}

.processmodal {
  background: linear-gradient(180deg, var(--bg), #070707);
  color: var(--text);
  padding: 20px 40px 20px 20px;
  border-radius: 12px;
  width: 90%;
  max-width: 600px;
  max-height: 80%;
  overflow-y: auto;
  position: relative;
}

.processmodal h2 {
  margin-top: 0;
  text-align: center;
}

.processmodal .close {
  position: absolute;
  top: 14px;
  right: 14px;
  font-size: 20px;
  cursor: pointer;
  color: var(--muted);
  background: none;
  border: none;
}

.processmodal .close:hover {
  color: var(--danger);
}

.tosmodal {
  background: linear-gradient(180deg, var(--bg), #070707);
  color: var(--text);
  padding: 20px 40px 20px 20px;
  border-radius: 12px;
  width: 90%;
  max-width: 600px;
  max-height: 80%;
  overflow-y: auto;
  position: relative;
}

.tosmodal h2 {
  margin-top: 0;
  text-align: left;
}

.tosmodal .close {
  position: absolute;
  top: 14px;
  right: 14px;
  font-size: 20px;
  cursor: pointer;
  color: var(--muted);
  background: none;
  border: none;
}

.tosmodal .close:hover {
  color: var(--danger);
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  justify-content: center;
  align-items: center;
  z-index: 1000;
}

.modal img {
  max-width: 90%;
  max-height: 90%;
}

.image-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 999;
  overflow: hidden;
}

.image-overlay.active {
  display: flex;
}

.image-overlay img {
  max-width: 90%;
  max-height: 90%;
  cursor: grab;
  transition: transform 0.1s ease;
}

.calculatemodal {
  max-width: 430px;
  padding: 24px;
}

.calculate-content {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.calculate-input-wrapper {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.calculate-input {
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--text);
  padding: 14px;
  border-radius: 4px;
  outline: none;
  font-size: 15px;
  transition: 0.2s ease;
}

.calculate-input:focus {
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: var(--ring);
}

.calculate-input::-webkit-outer-spin-button,
.calculate-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.calculate-input[type=number] {
  -moz-appearance: textfield;
  appearance: textfield;
}

.calculate-results {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 4px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.calculate-price {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 18px;
}

.calculate-price strong {
  font-size: 20px;
  font-weight: 700;
}

.frame-input-container {
  display: flex;
  align-items: stretch;
  overflow: hidden;
  border-radius: 4px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}

.frame-main-input {
  border: none;
  border-radius: 0;
  text-align: center;
  flex: 1;
  min-width: 0;
  background: transparent;
}

.frame-main-input:focus {
  box-shadow: none;
}

.frame-side-btn {
  width: 52px;
  border: none;
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font-size: 20px;
  cursor: pointer;
  transition: 0.2s ease;
  flex-shrink: 0;
}

.frame-side-btn:hover {
  background: rgba(255, 255, 255, 0.08);
}

.frame-side-btn:active {
  transform: scale(0.96);
}

.frame-main-input::-webkit-outer-spin-button,
.frame-main-input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.frame-main-input[type=number] {
  -moz-appearance: textfield;
  appearance: textfield;
}

.arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.12);
  background: var(--bg);
  color: var(--text);
  font-size: 22px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(0,0,0,.4);
  transition: .2s ease;
  z-index: 1001;
}

.arrow:hover {
  box-shadow: var(--ring);
}

.arrow:active {
  transform: translateY(-50%) scale(.96);
}

.arrow.left {
  left: 24px;
}

.arrow.right {
  right: 24px;
}

.zoom-controls {
  position: fixed;
  top: 18px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  background: var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  z-index: 1001;
}

.zoom-controls button {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
  transition: .2s ease;
}

.zoom-controls button:hover {
  box-shadow: var(--ring);
}

.zoom-controls button:active {
  transform: scale(.96);
}

.zoom-label {
  font-size: 13px;
  color: var(--muted);
  min-width: 50px;
  text-align: center;
}

.zoom-hint {
  font-size: 12px;
  opacity: 0.7;
}

.grid-island {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px;
  background: var(--bg);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  z-index: 999;
}

.grid-island button {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font-size: 18px;
  cursor: pointer;
}

.grid-island button:hover {
  box-shadow: var(--ring);
}

.grid-island span {
  font-size: 13px;
  color: var(--muted);
  min-width: 80px;
  text-align: center;
}

.importmodal {
  width: 95%;
  max-width: 1400px;
  max-height: 95vh;
  padding: 24px;
  overflow: hidden;
}

.importmodal::-webkit-scrollbar {
  display: none;
}

.importmodal video {
  width: 100%;
  max-height: 80vh;
  object-fit: contain;
}

.import-zoom-controls {
  display: flex;
  gap: 8px;
  justify-content: center;
  margin-bottom: 12px;
}

.import-zoom-controls button {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: white;
  border-radius: 6px;
  padding: 6px 12px;
  cursor: pointer;
}

#importVideo {
  width: 100%;
  border-radius: 12px;
  transform-origin: center center;
  transition: transform 0.15s ease;
}

#top-content {
  display: flex;
  gap: 18px;
  margin-bottom: 18px;
}

#prices {
  width: 475px;
}

#about {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

section#work {
  height: fit-content;
}

.pricesheightexpander {
  height: 5px;
}

footer {
  margin-top: 24px;
  text-align: left;
  color: var(--muted);
  font-size: 13px;
}

.review-trigger {
    position: relative;
    display: inline-block;
}

.review-trigger a {
    color: var(--e6edf3);
    text-decoration: none;
}

.review-trigger a:hover {
    color: var(--muted);
}

.review-popup {
    display: none;
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    padding: 8px 12px;
    border-radius: 6px;
    background: var(--bg);
    border: 1px solid rgba(255,255,255,0.08);
    color: var(--text);
    font-size: 12px;
    white-space: nowrap;
    box-shadow: var(--shadow);
    z-index: 9999;
}

.review-trigger:hover .review-popup {
    display: block;
}

.image-close-btn {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.12);
  background: var(--bg);
  color: var(--text);
  font-size: 24px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(8px);
  box-shadow: 0 10px 30px rgba(0,0,0,.4);
  transition: .2s ease;
  z-index: 1001;
}

.image-close-btn:active {
  transform: scale(.96);
}

#portfolioWrapper {
  position: relative;
}

.grid-island.stuck {
  position: absolute;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
}

.portfolio-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
}

.portfolio-tag,
.portfolio-date {
  font-size: 13px;
  color: var(--text);
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 3px;
  padding: 6px 10px;
  font-weight: 500;
}

.portfolio-tag {
  text-transform: capitalize;
}

.portfolio-date {
  white-space: nowrap;
  color: var(--muted);
}

.portfolio-left-meta {
  display: flex;
  align-items: center;
  gap: 6px;
}

.portfolio-recent {
  font-size: 13px;
  color: #22c55e;
  background: rgba(34,197,94,.12);
  border: 1px solid rgba(34,197,94,.25);
  border-radius: 3px;
  padding: 6px 10px;
  font-weight: 600;
  white-space: nowrap;
}

@media (max-width: 1200px) {
  #top-content {
    flex-direction: column;
  }

  #prices {
    width: 100%;
  }
}

@media (max-width: 1000px) {
  .cards {
    grid-template-columns: repeat(1, 1fr);
  }
  footer {
    margin-top: 24px;
    text-align: center;
    color: var(--muted);
    font-size: 13px;
  }
}

@media (min-width: 1500px) {
  main {
    grid-template-columns: 4.25fr 0.9fr;
  }
}

@media (min-width: 840px) {
  main {
    grid-template-columns: 1.4fr 0.9fr;
  }
}

@media (max-width: 600px) {
  header {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    position: relative;
    top: 0;
  }

  .title {
    margin-top: 4px;
    width: 100%;
  }

  .badges {
    flex-direction: column;
    gap: 8px;
    width: 100%;
  }

  .badgebtn {
    width: 100%;
    text-align: center;
  }
  .grid-island {
    bottom: 12px;
    gap: 8px;
    padding: 8px 10px;
    max-width: calc(100vw - 24px);
  }

  .grid-island button {
    width: 30px;
    height: 30px;
    font-size: 16px;
  }

  .grid-island span {
    min-width: 60px;
    font-size: 12px;
  }

  .grid-island.stuck {
    bottom: 12px;
  }
}