@import url("https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap");

:root {
  --bg-main: #050505;
  --bg-glass: rgba(15, 15, 15, 0.7);
  --bg-card: rgba(20, 20, 25, 0.6);
  --c-primary: #ffa500;
  --c-primary-dark: #cc8400;
  --c-primary-glow: rgba(255, 165, 0, 0.5);
  --c-secondary: #ff4500;
  --t-white: #ffffff;
  --t-muted: #a0a0a0;
  --border-glass: rgba(255, 165, 0, 0.2);
  --border-light: rgba(255, 255, 255, 0.08);
  --font-main: "Inter", sans-serif;
  --trans-fast: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  --trans-smooth: 0.5s cubic-bezier(0.165, 0.84, 0.44, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  background-color: var(--bg-main);
  color: var(--t-white);
  overflow-x: hidden;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

::-webkit-scrollbar {
  width: 10px;
}
::-webkit-scrollbar-track {
  background: var(--bg-main);
}
::-webkit-scrollbar-thumb {
  background: var(--c-primary-dark);
  border-radius: 10px;
}

.checkout-head {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 90px;
  background: var(--bg-glass);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-glass);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 5%;
  z-index: 1000;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
}

.nav-left {
  display: flex;
  align-items: center;
  gap: 30px;
}

.Logo img {
  max-width: 70px;
  transition: var(--trans-smooth);
}

.Logo:hover img {
  transform: scale(1.1) rotate(-5deg);
  filter: drop-shadow(0 0 15px var(--c-primary-glow));
}

.secure-badge {
  background: rgba(0, 255, 100, 0.1);
  border: 1px solid rgba(0, 255, 100, 0.3);
  padding: 8px 15px;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 800;
  color: #00ff64;
  text-transform: uppercase;
  letter-spacing: 2px;
  display: flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 0 15px rgba(0, 255, 100, 0.1);
}

.checkout-title {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 1px;
}

.count-check {
  color: var(--c-primary);
  text-shadow: 0 0 10px var(--c-primary-glow);
}

.checkout-main {
  flex: 1;
  padding: 130px 5% 80px;
  display: flex;
  justify-content: center;
}

.checkout-grid {
  display: grid;
  grid-template-columns: 1fr 450px;
  gap: 40px;
  width: 100%;
  max-width: 1500px;
  align-items: start;
}

.product-checkout {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  backdrop-filter: blur(20px);
  border-radius: 20px;
  padding: 30px;
  margin-bottom: 25px;
  position: relative;
  overflow: hidden;
  transition: var(--trans-smooth);
  animation: slideInLeft 0.6s cubic-bezier(0.165, 0.84, 0.44, 1) both;
}

.product-checkout:hover {
  transform: translateX(10px);
  border-color: var(--border-glass);
  box-shadow:
    0 15px 40px rgba(0, 0, 0, 0.8),
    0 0 20px rgba(255, 165, 0, 0.05);
}

.delivery-time {
  font-size: 1.3rem;
  font-weight: 800;
  color: #00ff64;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.product-data {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 30px;
  align-items: center;
}

.productImg {
  width: 100%;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.02);
  padding: 15px;
  filter: drop-shadow(0 10px 15px rgba(0, 0, 0, 0.5));
}

.name {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.price {
  font-size: 1.5rem;
  font-weight: 900;
  color: var(--c-primary);
  margin-bottom: 15px;
  text-shadow: 0 0 10px var(--c-primary-glow);
}

.price span {
  font-size: 1rem;
  color: var(--t-white);
}

.quantity-controls {
  display: flex;
  align-items: center;
  gap: 15px;
  margin-bottom: 25px;
}

.delete-btn {
  background: transparent;
  border: 1px solid var(--c-secondary);
  color: var(--c-secondary);
  padding: 8px 15px;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 700;
  transition: var(--trans-fast);
}

.delete-btn:hover {
  background: var(--c-secondary);
  color: #fff;
  box-shadow: 0 0 15px rgba(255, 69, 0, 0.4);
}

.delivery-options-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 15px;
  color: var(--t-muted);
}

.deliveryOptions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.delivery-option {
  display: flex;
  align-items: center;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.03);
  padding: 15px;
  border-radius: 12px;
  border: 1px solid transparent;
  transition: var(--trans-fast);
}

.delivery-option:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: var(--border-light);
}

.delivery-option input[type="radio"] {
  display: none;
}

.radio-custom {
  width: 20px;
  height: 20px;
  border: 2px solid var(--t-muted);
  border-radius: 50%;
  margin-right: 15px;
  position: relative;
  transition: var(--trans-fast);
}

.delivery-option input[type="radio"]:checked + .radio-custom {
  border-color: var(--c-primary);
  box-shadow: 0 0 10px var(--c-primary-glow);
}

.delivery-option input[type="radio"]:checked + .radio-custom::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 10px;
  height: 10px;
  background: var(--c-primary);
  border-radius: 50%;
}

.delivery-details {
  display: flex;
  flex-direction: column;
}

.delivery-date {
  font-weight: 700;
  color: #00ff64;
}

.delivery-price {
  font-size: 0.9rem;
  color: var(--t-muted);
  margin-top: 5px;
}

.summary-card {
  background: var(--bg-card);
  border: 1px solid var(--border-glass);
  backdrop-filter: blur(20px);
  border-radius: 25px;
  padding: 40px;
  position: sticky;
  top: 120px;
  animation: slideInRight 0.6s cubic-bezier(0.165, 0.84, 0.44, 1) both;
  box-shadow:
    0 20px 50px rgba(0, 0, 0, 0.8),
    inset 0 0 20px rgba(255, 165, 0, 0.05);
}

.summary-title {
  font-size: 1.8rem;
  font-weight: 800;
  margin-bottom: 30px;
  color: var(--c-primary);
  text-shadow: 0 0 15px var(--c-primary-glow);
}

.summary-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 15px;
  font-size: 1.1rem;
  color: var(--t-muted);
}

.summary-row span:last-child {
  color: var(--t-white);
  font-weight: 600;
}

.summary-divider {
  height: 1px;
  background: var(--border-light);
  margin: 20px 0;
}

.total-row {
  font-size: 1.6rem;
  font-weight: 900;
  color: var(--t-white);
  margin-bottom: 40px;
}

.total-price {
  color: var(--c-primary) !important;
  text-shadow: 0 0 15px var(--c-primary-glow);
}

.payment-title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 15px;
}

.payment-methods {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 15px;
  margin-bottom: 30px;
}

.payment-option input {
  display: none;
}

.payment-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 15px 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  transition: var(--trans-fast);
}

.payment-box i {
  font-size: 1.8rem;
  color: var(--t-muted);
  transition: var(--trans-fast);
}

.payment-box span {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--t-muted);
}

.payment-option input:checked + .payment-box {
  background: rgba(255, 165, 0, 0.1);
  border-color: var(--c-primary);
  box-shadow: 0 0 15px rgba(255, 165, 0, 0.2);
}

.payment-option input:checked + .payment-box i,
.payment-option input:checked + .payment-box span {
  color: var(--c-primary);
}

.policy-container {
  margin-bottom: 30px;
  background: rgba(255, 255, 255, 0.02);
  padding: 15px;
  border-radius: 12px;
  border: 1px solid var(--border-light);
}

.custom-checkbox {
  display: flex;
  align-items: center;
  cursor: pointer;
  position: relative;
}

.custom-checkbox input {
  display: none;
}

.checkmark {
  width: 24px;
  height: 24px;
  background: rgba(0, 0, 0, 0.5);
  border: 2px solid var(--t-muted);
  border-radius: 6px;
  margin-right: 15px;
  position: relative;
  transition: var(--trans-fast);
  flex-shrink: 0;
}

.custom-checkbox input:checked + .checkmark {
  background: var(--c-primary);
  border-color: var(--c-primary);
  box-shadow: 0 0 15px var(--c-primary-glow);
}

.custom-checkbox input:checked + .checkmark::after {
  content: "\f00c";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  color: var(--bg-main);
  font-size: 14px;
}

.policy-text {
  font-size: 0.9rem;
  color: var(--t-muted);
  line-height: 1.5;
}

.policy-text a {
  color: var(--c-primary);
  text-decoration: none;
  font-weight: 600;
  transition: var(--trans-fast);
}

.policy-text a:hover {
  text-shadow: 0 0 10px var(--c-primary-glow);
}

.place-order {
  position: relative;
  width: 100%;
  padding: 22px;
  background: var(--bg-main);
  border: none;
  border-radius: 16px;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 15px;
  overflow: hidden;
  z-index: 1;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* 1. Rotirajući laserski okvir (Conic Gradient) */
.place-order::before {
  content: "";
  position: absolute;
  top: -100%;
  left: -100%;
  width: 300%;
  height: 300%;
  background: conic-gradient(
    transparent,
    transparent,
    transparent,
    var(--c-primary),
    var(--c-secondary),
    transparent 20%
  );
  animation: spinBorder 4s linear infinite;
  z-index: -2;
}

/* 2. Unutrašnje jezgro koje prekriva sredinu lasera, ostavljajući samo ivicu od 2px */
.place-order::after {
  content: "";
  position: absolute;
  inset: 2px; /* Debljina svetleće ivice */
  background: linear-gradient(
    135deg,
    rgba(20, 20, 25, 0.95),
    rgba(30, 30, 40, 0.95)
  );
  border-radius: 14px; /* Malo manje od samog dugmeta */
  z-index: -1;
  transition: background 0.4s ease;
}

/* 3. Holografski svetlosni snop koji preleće preko dugmeta */
.place-order .btn-shimmer {
  position: absolute;
  top: 0;
  left: -150%;
  width: 50%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 165, 0, 0.4),
    transparent
  );
  transform: skewX(-25deg);
  transition: all 0.7s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: 0;
  pointer-events: none;
}

/* 4. Tekst dugmeta - Inicijalno je gradijent boje! */
.place-order .btn-text {
  position: relative;
  z-index: 2;
  font-size: 1.2rem;
  font-weight: 900;
  letter-spacing: 2px;
  background: linear-gradient(90deg, #fff, var(--c-primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  transition: all 0.4s ease;
  text-shadow: 0 0 20px rgba(255, 165, 0, 0.2);
}

.place-order i {
  position: relative;
  z-index: 2;
  font-size: 1.3rem;
  color: var(--c-primary);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* =========================================
   HOVER EFEKTI (Kada magija počinje)
   ========================================= */

/* Podizanje i moćna senka */
.place-order:hover {
  transform: translateY(-5px) scale(1.02);
  box-shadow:
    0 20px 40px rgba(255, 165, 0, 0.3),
    0 0 25px rgba(255, 69, 0, 0.2);
}

/* Ubrzavamo rotaciju lasera i pojačavamo boje na hover */
.place-order:hover::before {
  background: conic-gradient(
    transparent,
    var(--c-primary),
    var(--c-secondary),
    var(--c-primary),
    transparent 50%
  );
  animation: spinBorder 1.5s linear infinite; /* Turbo brzina */
}

/* Unutrašnjost postaje prozirna i obojena primarnom bojom */
.place-order:hover::after {
  background: linear-gradient(
    135deg,
    rgba(204, 132, 0, 0.2),
    rgba(255, 69, 0, 0.1)
  );
  backdrop-filter: blur(10px);
}

/* Ispaljujemo svetlosni snop sa leve na desnu stranu */
.place-order:hover .btn-shimmer {
  left: 200%;
}

/* Tekst postaje potpuno beo i dobija neonsku senku (Glow) */
.place-order:hover .btn-text {
  -webkit-text-fill-color: #fff;
  text-shadow: 0 0 15px rgba(255, 255, 255, 0.9);
}

/* Strelica leti napred, postaje bela i uveličava se */
.place-order:hover i {
  transform: translateX(12px) scale(1.3);
  color: #fff;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.8));
}

/* Click / Active efekat (Osećaj pritiska) */
.place-order:active {
  transform: translateY(2px) scale(0.98);
  box-shadow: 0 5px 15px rgba(255, 165, 0, 0.4);
}

/* Ključni kadrovi za rotaciju laserske ivice */
@keyframes spinBorder {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.shake {
  animation: shakeError 0.5s cubic-bezier(0.36, 0.07, 0.19, 0.97) both;
  border-color: var(--c-secondary) !important;
  box-shadow: 0 0 15px rgba(255, 69, 0, 0.4) !important;
}

.success-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  z-index: 9999;
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: var(--trans-smooth);
}

.success-overlay.show {
  opacity: 1;
  pointer-events: all;
}

.success-card {
  background: var(--bg-card);
  border: 1px solid rgba(0, 255, 100, 0.3);
  padding: 50px;
  border-radius: 30px;
  text-align: center;
  transform: scale(0.8);
  opacity: 0;
  transition: var(--trans-smooth);
  box-shadow:
    0 30px 60px rgba(0, 0, 0, 0.9),
    inset 0 0 50px rgba(0, 255, 100, 0.1);
  max-width: 500px;
}

.success-overlay.show .success-card {
  transform: scale(1);
  opacity: 1;
}

.success-icon-wrapper {
  position: relative;
  width: 100px;
  height: 100px;
  margin: 0 auto 30px;
  display: flex;
  justify-content: center;
  align-items: center;
  font-size: 3rem;
  color: #00ff64;
}

.success-ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 4px solid #00ff64;
  border-radius: 50%;
  box-shadow:
    0 0 20px rgba(0, 255, 100, 0.4),
    inset 0 0 20px rgba(0, 255, 100, 0.4);
  animation: scalePulse 2s infinite cubic-bezier(0.165, 0.84, 0.44, 1);
}

.success-card h2 {
  font-size: 2.2rem;
  font-weight: 800;
  color: #00ff64;
  margin-bottom: 15px;
  text-shadow: 0 0 15px rgba(0, 255, 100, 0.3);
}

.success-card p {
  font-size: 1.1rem;
  color: var(--t-muted);
  line-height: 1.6;
  margin-bottom: 30px;
}

.loading-bar-container {
  width: 100%;
  height: 6px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 15px;
}

.loading-bar {
  width: 0%;
  height: 100%;
  background: #00ff64;
  box-shadow: 0 0 10px #00ff64;
}

.success-overlay.show .loading-bar {
  animation: loadProgress 3s linear forwards;
}

.redirect-text {
  font-size: 0.9rem !important;
  color: var(--t-white) !important;
  font-weight: 700;
  margin-bottom: 0 !important;
}

@keyframes slideInLeft {
  0% {
    opacity: 0;
    transform: translateX(-50px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideInRight {
  0% {
    opacity: 0;
    transform: translateX(50px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes shakeError {
  10%,
  90% {
    transform: translate3d(-1px, 0, 0);
  }
  20%,
  80% {
    transform: translate3d(2px, 0, 0);
  }
  30%,
  50%,
  70% {
    transform: translate3d(-4px, 0, 0);
  }
  40%,
  60% {
    transform: translate3d(4px, 0, 0);
  }
}

@keyframes scalePulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  100% {
    transform: scale(1.3);
    opacity: 0;
  }
}

@keyframes loadProgress {
  0% {
    width: 0%;
  }
  100% {
    width: 100%;
  }
}

@media (max-width: 1024px) {
  .checkout-grid {
    grid-template-columns: 1fr;
  }
  .summary-card {
    position: relative;
    top: 0;
  }
}

@media (max-width: 768px) {
  .product-data {
    grid-template-columns: 1fr;
    text-align: center;
  }
  .productImg {
    max-width: 200px;
    margin: 0 auto;
  }
  .quantity-controls {
    justify-content: center;
  }
  .checkout-head {
    padding: 0 20px;
  }
  .checkout-title {
    font-size: 1.2rem;
  }
}
.input-group input:focus:valid {
  border-color: #2ecc71;
  box-shadow: 0 0 10px rgba(46, 204, 113, 0.2);
}

/* Animacija za pojavljivanje error poruka */
.error-message {
  font-size: 12px;
  color: #ff4757;
  margin-top: 5px;
  display: none;
  animation: fadeIn 0.3s ease;
}
@media (min-width: 1025px) {
  .checkout-grid {
    display: grid;
    grid-template-columns: 1fr 400px; /* Ovo već imaš, ali proveri */
    gap: 40px;
    align-items: start; /* OBAVEZNO: sprečava da se kolona rastegne */
  }

  .summary-section {
    position: sticky;
    top: 110px; /* Podešava razmak od vrha ekrana dok skroluješ */
    z-index: 10;
  }
}
.shake-error {
  animation: shake 0.4s ease-in-out;
  border-color: #ff4757 !important;
}

@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }
  25% {
    transform: translateX(-5px);
  }
  75% {
    transform: translateX(5px);
  }
}
.trust-badges-container {
  margin-top: 25px;
  padding-top: 20px;
  border-top: 1px solid var(--border-light);
  text-align: center;
}

.trust-text {
  font-size: 0.8rem;
  color: var(--t-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  margin-bottom: 12px;
  font-weight: 600;
}

.trust-icons {
  display: flex;
  justify-content: center;
  gap: 20px;
  font-size: 1.8rem; /* Veličina ikonica */
  color: var(--t-muted);
  opacity: 0.6;
  transition: var(--trans-fast);
}

/* Na hover postaju svetlije i dobijaju tvoju primarnu boju */
.trust-badges-container:hover .trust-icons {
  opacity: 1;
}

.trust-icons i:hover {
  color: var(--c-primary);
  transform: translateY(-3px);
  filter: drop-shadow(0 0 8px var(--c-primary-glow));
}
.empty-checkout {
  grid-column: 1 / -1; /* Zauzima ceo red ako grid ima dve kolone */
  text-align: center;
  padding: 60px 20px;
  background: var(--bg-card);
  border: 1px dashed var(--border-glass);
  border-radius: 20px;
  animation: fadeIn 0.6s ease;
}

.empty-icon-wrapper {
  width: 100px;
  height: 100px;
  background: rgba(255, 165, 0, 0.05);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 25px;
  font-size: 3rem;
  color: var(--c-primary);
  box-shadow: 0 0 30px rgba(255, 165, 0, 0.1);
}

.empty-checkout h2 {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 15px;
  background: linear-gradient(90deg, #fff, var(--c-primary));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.empty-checkout p {
  color: var(--t-muted);
  font-size: 1.1rem;
  max-width: 500px;
  margin: 0 auto 35px;
  line-height: 1.6;
}

.return-btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  padding: 16px 32px;
  background: var(--c-primary);
  color: #000;
  text-decoration: none;
  font-weight: 900;
  border-radius: 12px;
  letter-spacing: 1px;
  transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  box-shadow: 0 10px 20px rgba(255, 165, 0, 0.2);
}

.return-btn:hover {
  transform: translateY(-5px) scale(1.05);
  box-shadow: 0 15px 30px var(--c-primary-glow);
  color: #fff;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
