@import url('styles.css');

body.dark .agreement  {
  color: #333;
}

.cart-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding: 82px 16px;
  overflow: hidden;
  background: rgb(0 0 0 / 45%);
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s ease, visibility .3s ease;
}

.cart-modal.show {
  opacity: 1;
  visibility: visible;
}

.cart-modal-content {
  background: #fefefe;
  margin: 0; 
  padding: 20px;
  border-radius: 5px;
  max-width: 800px;
  width: 100%;
  max-height: calc(100dvh - 164px);
  overflow: auto;
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
  transform: translateY(-30px);
  opacity: 0;
  transition: transform .3s ease, opacity .3s ease;
}

.cart-modal.show .cart-modal-content {
  transform: translateY(0);
  opacity: 1;
}

.cart-modal-content h3 {
  font-size: 16px;
  
}

.subs {
  display: flex;
  flex-direction: column;
  gap: 15px;
  margin-bottom: 20px;
}

.cart-plan {
  font-family: var(--font-family);
  padding: 15px;
  font-size: 16px;
  color: var(--title-color-text);
  background-color: #f9f9f9;
  border: 1px solid #ddd;
  border-radius: 5px;
  text-align: left;
  display: flex;
  justify-content: space-between;
  align-items: center;
  cursor: pointer;
  transition: background-color 0.3s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.cart-plan:hover {
  color: var(--hover-color);
  background-color: #f0f0f0;
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.312);
}

.cart-plan.selected {
  border-color: #4caf50;
  background-color: #e6ffe6;
}

.cart-plan:active {
  background-color: #ddd;
  transform: translateY(0);
}

.cart-title {
  display: flex;
  justify-content: left;
  font-size: 24px;
  color: #333;
  padding-bottom: 15px;
}

.border-cart-title {
  margin: 0 0 20px;
  border-bottom: 1px solid #ddd;
}

.title-plan {
  margin-bottom: 20px;;
}

.plan-subs {
  font-family: var(--font-family);
  font-size: 14px;
}

#paymentHistory {
  margin-top: 20px;
}

#paymentHistory ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.last-payment {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 10px;
  background: #f9f9f9;
  border: 1px solid #ccc;
  border-radius: 5px;
  margin-top: 10px;
}

.payment-amount {
  padding-left: 70px;
}

.payment-item {
  color: var(--title-color-text);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid #ddd;
  transition: color 0.3s ease, transform 0.2s ease;
}

.payment-header {
  display: flex;
  justify-content: space-between;
  width: 100%;
  font-weight: bold;
  font-size: 14px;
  color: #333;
  border-bottom: 1px solid #ddd;
  padding-bottom: 5px;
  margin-bottom: 5px;
}

.payment-data {
  display: flex;
  justify-content: space-between;
  width: 100%;
  font-size: 14px;
  color: #555;
}

.payment-item:hover {
  color: var(--hover-color);
}

.subscribe-button {
  width: 250px;
  margin-left: 20px;
  padding: 5px 10px;
  
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.3s ease, transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: -1px 1px 2px 0px rgba(191, 191, 191, 0.71);
}

.subscribe-button:disabled {
  background: #ccc;
  cursor: not-allowed;
}

.subscribe-button:hover:enabled {
  transform: translateY(-2px);
  background: linear-gradient(135deg, #059669, #10b981);
  box-shadow: 0 10px 20px rgba(16, 185, 129, 0.4);
}

.checkbox {
  margin-bottom: 30px;
}

.agreement {
  font-family: var(--font-family);
  font-size: 12px;

}

.agreement a {
  color: blue;
}

.history {
  display: flex;
  justify-content: space-between;
  margin-bottom: 20px;
}
.history h4 {
  color: #aaa;
}

.checkbox-container.disabled {
  pointer-events: none;
  opacity: 0.5; 
}

.checkbox-container {
    display: flex;
    align-items: center; 
    gap: 10px; 
    
  pointer-events: none;
  max-width: 400px;
  border: 1px solid #3333333b;
  border-radius: 5px;
  padding: 10px;
  transition: opacity 0.3s ease;
  margin-bottom: 20px;
}

input[type="checkbox"]:checked {
  accent-color: #b6e1b8;
  pointer-events: none;
}

.checkbox-button-container {
  display: flex;
  justify-content: space-between;
}


@media (max-width: 768px) {
  .checkbox-button-container {
  display: flex;
  flex-direction: column;
}

.checkbox-container {
  margin: 0  auto 20px;
}

.subscribe-button {
  margin: 0 auto;
  width: 80%;
}

.plan-subs {
  font-size: 12px;
}

.cart-plan {
  padding: 10px;
  font-size: 14px;
}
}

#downloadHistory[style*="pointer-events: none"] {
  color: gray;
  cursor: not-allowed;
}

.card {
  padding: 0 10px;
  margin-bottom: 20px;
}

.summary-list,
#paymentList {
  text-align: left;  
  list-style: none;
  padding-left: 0;
}

.summary-list li,
.payment-item {
  text-align: left; 
  padding: 2px 0;
  border-bottom: 1px dashed #ddd;
}

.summary-list li:last-child,
#paymentList li:last-child {
  border-bottom: none;
}

.summary-list li strong,
.summary-list li span {
  font-size: 12px;
}

.plan-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
}

.current-plan {
  display: flex;
}


.current-plan strong {
  margin-right: 5px;
}

.download-link-inline {
  color: var(--title-color-text);
  font-size: 12px;
  text-decoration: none;
  margin-left: 10px;
  transition: color var(--main-transition);
}

.download-link-inline:hover {
  color: #45a049;
}

.download-link-inline.disabled {
  color: gray !important;
  pointer-events: none;
  cursor: default;
  text-decoration: none;
}


.last-payment-text {
  font-size: 1rem;
  font-weight: 500;
  color: var(--title-color-text);
  margin-bottom: 10px;
}

.next-invoice-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.cancel-btn {
  font-family: var(--font-family);
  background: transparent;
  color: var(--title-color-text);
  border: none;
  cursor: pointer;
  font-size: 12px;
  padding: 0;
  transition: color var(--main-transition);
}

.cancel-btn:hover {
  color: rgb(187, 74, 74);
}

.subscription-status {
  font-weight: 500;
  margin-left: 0.5rem;
}

.subscription-status.active {
  color: #4caf50;
}

.subscription-status.canceled {
  color: #e74c3c;
}

.tooltip-icon {
  display: inline-block;
  margin-left: 6px;
  color: #888;
  font-weight: bold;
  cursor: help;
}

.toogle-container {
  display: flex;
  justify-content: space-between;
  align-items: baseline
}

.billing-toggle {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  font-size: 14px;
  margin-bottom: 10px;
}

.switch-plan {
  position: relative;
  display: inline-block;
  width: 40px;
  height: 20px;
}

.switch-plan input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider-plan {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #a4a4a4;
  transition: .4s;
  border-radius: 20px;
}

.slider-plan::before {
  position: absolute;
  content: "";
  height: 14px;
  width: 14px;
  left: 3px;
  top: 3px;
  background-color: white;
  transition: 0.4s;
  border-radius: 50%;
}

.switch-plan input:checked + .slider-plan {
  background-color: #4caf50;
}

.switch-plan input:checked + .slider-plan::before {
  transform: translateX(20px);
}

.discount-label {
  position: absolute;
  margin-bottom: 45px;
  right: 25px; 
  font-size: 12px;
  font-weight: bold;
  color: red;
  background: rgba(255, 0, 0, 0.15);
  padding: 1px 3px;
  border-radius: 3px;
}