html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

/* Product card image: a fixed 3:2 frame (matching the upload canvas). The whole
   image is always shown (never cropped); any spare space is padded with white. */
.product-thumb {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: contain;
  object-position: center;
  background-color: #ffffff;
}

/* Fallback for browsers without aspect-ratio support. */
@supports not (aspect-ratio: 3 / 2) {
  .product-thumb {
    height: 0;
    padding-bottom: 66.666%;
  }
}

/* ---- Navigation bar: blue / black / red ---- */
:root {
  --site-blue: #009de0;
  --site-red: #d21f28;
  --site-black: #0a0a0a;
}

.site-navbar {
  background-color: var(--site-black);
  border-bottom: 3px solid var(--site-red);
}

.site-navbar .navbar-brand {
  color: #ffffff;
  font-weight: 700;
  letter-spacing: .5px;
}

.site-navbar .navbar-brand:hover,
.site-navbar .navbar-brand:focus {
  color: var(--site-blue);
}

.site-navbar .nav-link {
  color: #d7dbe0;
  border-bottom: 2px solid transparent;
  transition: color .12s, border-color .12s;
}

.site-navbar .nav-link:hover,
.site-navbar .nav-link:focus {
  color: #ffffff;
  border-bottom-color: var(--site-blue);
}

.site-navbar .nav-link.active {
  color: #ffffff;
  border-bottom-color: var(--site-red);
}

.site-navbar .navbar-text {
  color: #aeb4bd;
}

.site-navbar .navbar-toggler {
  border-color: rgba(255, 255, 255, .3);
}

/* ---- Craftnetics landing page ---- */

/* Full-bleed banner on the home page: breaks out of the Bootstrap .container
   so it spans the whole viewport width. */
.site-banner {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  padding: 14px 0;
  /* soft gray shading gives the strip a raised, 3D frame */
  background: linear-gradient(180deg, #f4f4f5 0%, #e6e6e9 50%, #d6d6da 100%);
  box-shadow: 0 14px 30px -10px rgba(0, 0, 0, 0.3);
}

/* inset gray gradient along the top and bottom edges for extra depth */
.site-banner::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  box-shadow: inset 0 10px 22px -8px rgba(80, 80, 80, 0.5),
              inset 0 -10px 22px -8px rgba(80, 80, 80, 0.5);
}

.site-banner-img {
  display: block;
  width: 100%;
  height: auto;              /* scale with viewport width, keep aspect ratio */
  max-height: 60vh;          /* never taller than 60% of the screen */
  object-fit: contain;       /* show the whole image, no cropping */
  object-position: center;
  /* drop the JPG's white background into the gray banner gradient */
  mix-blend-mode: multiply;
}

/* ---- Auth splash screen (sign in / register) ---- */
.auth-splash {
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  /* fill the viewport below the navbar, minus footer breathing room */
  min-height: calc(100vh - 130px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem;
  background: linear-gradient(135deg, #009de0 0%, #0079b3 55%, #ec008c 135%);
}

.auth-card {
  width: 100%;
  max-width: 460px;
  background: #ffffff;
  border-radius: 1rem;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.25);
  padding: 2.5rem;
}

@media (max-width: 575.98px) {
  .auth-card {
    padding: 1.75rem 1.25rem;
  }
}

/* Home page logo in a centred rounded placeholder */
.logo-placeholder {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  overflow: hidden;
  background: #ffffff;
  border: 4px solid var(--site-blue);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

@media (min-width: 768px) {
  .logo-placeholder {
    width: 240px;
    height: 240px;
  }
}

.logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  padding: 0.75rem;
}

.hero-craft {
  background: linear-gradient(135deg, #009de0 0%, #0079b3 55%, #ec008c 135%);
  color: #ffffff;
  border-radius: 1rem;
}

.hero-craft .btn-light {
  color: #0079b3;
}

.hero-chip {
  display: inline-block;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 999px;
  padding: 0.35rem 0.9rem;
}

.services-section {
  background-color: #009de0;
  color: #ffffff;
  border-radius: 1rem;
}

.service-card {
  height: 100%;
  background: #ffffff;
  color: #212529;
  border-radius: 0.75rem;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.12);
}

.service-card ul {
  padding-left: 1.1rem;
}

.service-icon {
  font-size: 2rem;
  line-height: 1;
  margin-bottom: 0.5rem;
}

/* Product gallery thumbnails on the shop detail page */
.thumb-btn {
  background: #fff;
  cursor: pointer;
  line-height: 0;
  opacity: 0.7;
  transition: opacity .15s, border-color .15s;
}

.thumb-btn:hover {
  opacity: 1;
}

.thumb-btn.active {
  opacity: 1;
  border-color: #0d6efd !important;
  box-shadow: 0 0 0 2px rgba(13, 110, 253, .25);
}