/* Polish layer for the Food for Rhinos mirror — subtle refinements only.
   Injected on every page after the main Webflow stylesheet. */

/* --- global rendering --- */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

::selection {
  background: #5baa1a;
  color: #fff;
}

/* slim, unobtrusive scrollbar (WebKit) */
::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: #151515;
}
::-webkit-scrollbar-thumb {
  background: #3d3d3d;
  border-radius: 5px;
  border: 2px solid #151515;
}
::-webkit-scrollbar-thumb:hover {
  background: #5baa1a;
}

/* visible keyboard focus in brand green */
:focus-visible {
  outline: 2px solid #5baa1a;
  outline-offset: 3px;
}

/* --- page entrance --- */
@keyframes pol-page-fade {
  from { opacity: 0; }
  to { opacity: 1; }
}
body {
  animation: pol-page-fade 0.5s ease-out both;
}

/* --- glassy fixed navbar --- */
.nav-bar {
  -webkit-backdrop-filter: blur(14px) saturate(1.2);
  backdrop-filter: blur(14px) saturate(1.2);
  background-color: rgba(10, 12, 8, 0.42);
  transition: background-color 0.35s ease;
}

/* --- buttons: gentle lift + press feedback --- */
.button {
  transition: background-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
  will-change: transform;
}
.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px -10px rgba(91, 170, 26, 0.55);
}
.button:active {
  transform: translateY(0);
  box-shadow: 0 4px 12px -8px rgba(91, 170, 26, 0.5);
}
.button.ghost:hover,
.button.white:hover {
  box-shadow: 0 10px 24px -12px rgba(0, 0, 0, 0.45);
}

/* --- social buttons: subtle lift --- */
.social-button {
  transition: transform 0.25s ease, opacity 0.25s ease;
}
.social-button:hover {
  transform: translateY(-3px) scale(1.08);
}

/* --- gallery / card imagery: slow zoom on hover --- */
.work-v1-thumb {
  border-radius: 16px;
}
.work-v1-thumb .zoomed-image {
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}
.work-v1:hover .zoomed-image {
  transform: scale(1.06);
}

.post-v1-thumb {
  overflow: hidden;
}
.post-v1-image {
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: transform;
}
.post-v1-thumb:hover .post-v1-image {
  transform: scale(1.05);
}

.brix---image-wrapper-br-24px {
  overflow: hidden;
}
.brix---image-wrapper-br-24px .brix---image {
  transition: transform 0.8s cubic-bezier(0.22, 1, 0.36, 1);
}
.brix---image-wrapper-br-24px:hover .brix---image {
  transform: scale(1.04);
}

/* team avatars (our family / milk monsters) */
.brix---avatar-image-square {
  transition: transform 0.35s ease, box-shadow 0.35s ease;
  border-radius: 12px;
}
.brix---avatar-image-square:hover {
  transform: translateY(-4px);
  box-shadow: 0 18px 36px -18px rgba(0, 0, 0, 0.55);
}

/* --- form fields (get involved) --- */
.input,
.w-input,
.w-select {
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
.input:focus,
.w-input:focus,
.w-select:focus {
  border-color: #5baa1a;
  box-shadow: 0 0 0 3px rgba(91, 170, 26, 0.18);
}

/* --- scroll-reveal system (elements tagged by polish.js) --- */
[data-pol] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1),
    transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
  will-change: opacity, transform;
}
[data-pol].pol-in {
  opacity: 1;
  transform: none;
}

/* --- readability --- */
/* body copy was #888 on cream (~3.4:1); #666 passes WCAG AA on all light sections */
.text-grey {
  color: #666;
}
/* logo subtitle was 9px */
.logo-description {
  font-size: 11px;
  line-height: 17px;
}

/* --- back-to-top: only show once the visitor has actually scrolled --- */
.top-button {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease, background-color 0.6s;
}
html.pol-scrolled .top-button {
  opacity: 1;
  pointer-events: auto;
}

/* --- PayFast donation form: match the site's own form styling --- */
form[name="PayFastPayNowForm"] table {
  width: 100%;
  border-collapse: collapse;
}
form[name="PayFastPayNowForm"] td {
  padding: 4px 0;
}
form[name="PayFastPayNowForm"] label {
  font-family: "Roboto Condensed", sans-serif;
  text-transform: uppercase;
  letter-spacing: 2px;
  font-size: 13px;
  color: #383838;
}
#PayFastAmount {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 44px;
  background: #fff;
  border: 1px solid #d1d1d1;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 16px;
  font-family: inherit;
  color: #151515;
  transition: border-color 0.25s ease, box-shadow 0.25s ease;
}
#PayFastAmount:focus {
  border-color: #5baa1a;
  box-shadow: 0 0 0 3px rgba(91, 170, 26, 0.18);
  outline: none;
}
form[name="PayFastPayNowForm"] .button {
  width: 100%;
  margin-top: 8px;
}

/* safety net: ensure the Webflow badge stays hidden */
.w-webflow-badge {
  display: none !important;
}

/* --- accessibility: no motion when the visitor asks for none --- */
@media (prefers-reduced-motion: reduce) {
  body {
    animation: none;
  }
  [data-pol] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .button,
  .social-button,
  .zoomed-image,
  .post-v1-image,
  .brix---image,
  .brix---avatar-image-square {
    transition: none !important;
  }
}
