/* =============================================
   GLOBAL STYLES - Dipakai di semua halaman
   ============================================= */

/* ===== SMOOTH SCROLL ===== */
html {
  scroll-behavior: smooth;
}

/* ===== OFFSET UNTUK WORK SECTION ===== */
#work-section {
  scroll-margin-top: 80px;
}

/* ===== ACCESSIBILITY: FOCUS INDICATOR ===== */
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
  outline: 2px solid #31BA90;
  outline-offset: 2px;
  border-radius: 4px;
}

/* ===== IMAGE OPTIMIZATION ===== */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ===== BOX SIZING UNIFORM ===== */
*,
*::before,
*::after {
  box-sizing: border-box;
}

/* ===== SCROLLBAR STYLING (OPSIONAL) ===== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: rgba(0, 0, 0, 0.1);
}

::-webkit-scrollbar-thumb {
  background: #31BA90;
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: #28a07a;
}

/* ===== SELECTION COLOR ===== */
::selection {
  background: #31BA90;
  color: #fff;
}

::-moz-selection {
  background: #31BA90;
  color: #fff;
}

/* ===== UTILITY CLASSES ===== */
.text-center {
  text-align: center;
}

.text-white {
  color: #ffffff;
}

.text-green {
  color: #31BA90;
}

.hidden {
  display: none !important;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* ===== RESPONSIVE FIXES ===== */

/* Tablet */
@media (max-width: 1024px) {
  #work-section {
    scroll-margin-top: 60px;
  }
}

/* Mobile */
@media (max-width: 768px) {
  #work-section {
    scroll-margin-top: 50px;
  }
  
  ::-webkit-scrollbar {
    width: 4px;
    height: 4px;
  }
}

/* ===== SAFARI FIXES ===== */
@supports (-webkit-touch-callout: none) {
  /* Fix untuk Safari */
  .header-hero {
    min-height: -webkit-fill-available;
  }
}
