/* Importing fonts */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@700&family=Inter:wght@700&display=swap');

/* Animation keyframes */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes tooltipFadeBethink {
  from { opacity: 0; transform: translateX(-50%) translateY(10px); }
  to   { opacity: 1; transform: translateX(-50%) translateY(-5px); }
}

/* با پیشوند برای مرورگرهای قدیمی‌تر WebKit */
@-webkit-keyframes tooltipFadeBethink {
  from { opacity: 0; -webkit-transform: translateX(-50%) translateY(10px); transform: translateX(-50%) translateY(10px); }
  to   { opacity: 1; -webkit-transform: translateX(-50%) translateY(-5px);  transform: translateX(-50%) translateY(-5px);  }
}
@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.8); }
    to { opacity: 1; transform: scale(1); }
}
@keyframes pulseShadow {
    0% { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); }
    50% { box-shadow: 0 6px 20px rgba(59, 130, 246, 0.2); }
    100% { box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); }
}

/* Remove box styling from ctc-payment-container to maximize space */
.ctc-payment-container {
    direction: rtl;
    margin: 0;
    padding: 0;
    border: none;
    background: none;
    max-width: 100%;
    text-align: right;
}

/* Ensure text alignment for child elements */
.ctc-payment-container p, .ctc-payment-container span, .ctc-payment-container label,
.ctc-payment-container input, .ctc-payment-container textarea, .ctc-payment-container select {
    text-align: right !important;
}

/* Styling for payment gateways without a surrounding box */
.ctc-account-options {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: center;
    margin-bottom: 1.5rem;
    background: none; /* Remove background */
    border: none; /* Remove border */
    padding: 0; /* Remove padding */
    box-shadow: none; /* Remove shadow */
    position: relative;
    z-index: 10;
}

.ctc-account-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0.75rem;
    background: #ffffff; /* White background */
    border-radius: 0.75rem;
    border: 1px solid rgba(209, 213, 219, 0.3); /* Light gray border */
    transition: all 0.3s ease;
    position: relative;
    opacity: 0;
    animation: fadeInUp 0.5s ease-out forwards;
    animation-delay: var(--animation-delay);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    z-index: 10;
    width: fit-content; /* Size based on content */
    flex: 0 0 auto; /* Prevent stretching, allow natural sizing */
}

.ctc-account-option.ctc-selected {
    background: #ffffff; /* Keep white background */
    border-color: #60A5FA; /* Blue border for selected state */
    box-shadow: 0 6px 20px rgba(96, 165, 250, 0.2);
    transform: scale(1.05);
}

.ctc-account-option:hover {
    background: #f0f8ff; /* Light blue on hover for contrast */
    transform: scale(1.08);
    box-shadow: 0 8px 25px rgba(96, 165, 250, 0.25);
    border-color: #60A5FA;
    z-index: 20;
}

.ctc-option-icon {
    height: 3rem !important;
    margin-bottom: 0.75rem !important;
    border: 2px solid rgba(255, 255, 255, 0.2) !important;
    transition: transform 0.3s ease !important;
    border-radius: 0.5rem;
}

.ctc-account-option:hover .ctc-option-icon {
    transform: scale(1.1);
}

.ctc-option-label {
    color: #1f2937;
    font-size: 0.9rem;
    font-weight: 600;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.ctc-tooltip {
    display: none;
    position: absolute;
    top: calc(-100% + 1.5rem);
    left: 50%;
    transform: translateX(-50%);
    padding: 0.5rem 0.75rem;
    font-size: 0.85rem;
    line-height: 1.4;
    color: #ffffff;
    white-space: nowrap;
    text-align: right;
    background-color: rgb(90, 90, 90);
    border-radius: 0.5rem;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    z-index: 9999;
    opacity: 0;
    transition: opacity 0.3s ease-in-out, transform 0.3s ease-in-out;
}

.ctc-tooltip:not(.hidden) {
    display: block;
    opacity: 1;
    transform: translateX(-50%) translateY(-5px);
    animation: tooltipFadeIn 0.3s ease-in-out;
}

.ctc-tooltip::after {
    content: '';
    position: absolute;
    bottom: -0.5rem;
    top:  75px;
    left: 50%;
    transform: translateX(-50%);
    border: 0.5rem solid transparent;
    border-top-color: rgba(31, 41, 55, 0.41);
    z-index: 31;
}

.ctc-account-details {
    margin-bottom: 1.5rem;
    z-index: 5;
}

.ctc-placeholder-text, .ctc-error-text {
    color: #6b7280;
    font-weight: 500;
}

.ctc-error-text {
    color: #dc2626;
}

.ctc-general-fields, .ctc-qr-fields {
    background: #ffffff; /* White background */
    border: 1px solid rgba(209, 213, 219, 0.5); /* Light gray border */
    border-radius: 1rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.ctc-field-row {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    justify-content: space-between;
    margin-bottom: 1rem;
}

.ctc-field-group {
    flex: 1;
    min-width: 200px;
    max-width: 300px;
}

.ctc-field-group.ctc-full-width {
    flex: 0 0 100%;
    max-width: 100%;
}

.ctc-field-label {
    display: block;
    color: #374151;
    margin-bottom: 0.25rem;
    font-size: 0.875rem;
    font-weight: 500;
}

.ctc-required {
    color: #dc2626;
}

.ctc-input, .ctc-textarea, .ctc-select {
    width: 100%;
    padding: 0.5rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    display: block;
}

.ctc-input:focus, .ctc-textarea:focus, .ctc-select:focus {
    outline: none;
    border-color: #60A5FA;
    box-shadow: 0 0 0 2px rgba(96, 165, 250, 0.5);
}

.ctc-time-input {
    max-width: 100%;
}

.ctc-details-box-header {
    background-color: rgba(168, 181, 162, 0.1);
    padding: 1rem;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(168, 181, 162, 0.2);
    border: 1px solid rgba(168, 181, 162, 0.3);
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    width: fit-content;
    margin: 1rem auto 0;
    word-break: break-word;
    white-space: normal;
    font-size: 1rem;
    line-height: 1.5;
    text-align: center;
    color: #333;
    transition: all 0.25s ease-in-out;
}

.ctc-details-box-header .info-title {
    font-size: 1.2rem;
    font-weight: 700;
    color: #2d2d2d;
}

.ctc-details-box-header .info-box-container {
    display: flex;
    flex-direction: row;
    gap: 16px;
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
}

.ctc-details-box-header .bank-info-box, .ctc-details-box-header .holder-info-box {
    background-color: #fefefe;
    border: 1px dashed #d2d2d2;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    color: #2d2d2d;
    display: flex;
    align-items: center;
    gap: 8px;
    direction: rtl;
    text-align: right;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    flex: 1;
    min-width: 200px;
    max-width: 300px;
}

.ctc-number-box {
    background-color: #ffffff03;
    padding: 12px 16px;
    border-radius: 1rem;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    border: 1px solid #D1D5DB;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center; /* Center align content */
    gap: 1rem;
    width: fit-content;
    margin: 1rem auto;
    word-break: break-word;
    white-space: normal;
    line-height: 1.5; /* ← اینجا ; اضافه شد */
    text-align: center; /* Center align text */
    color: #203D66FA;
    font-family: 'Roboto', 'Inter', sans-serif;
    font-weight: 800;
    font-size: 15px;
    transition: all 0.25s ease-in-out;
    animation: pulseShadow 2s ease-in-out infinite;
}


.ctc-number-box.copied {
    background-color: rgba(52, 211, 153, 0.1);
    box-shadow: 0 4px 12px rgba(52, 211, 153, 0.2);
    border: 1px solid rgba(52, 211, 153, 0.3);
    color: #1F2937;
    animation: fadeInUp 0.3s ease-out, pulseShadow 2s ease-in-out infinite;
}

.ctc-copy-button {
    background-color: #60A5FA;
    color: #F3F4F6;
    padding: 10px 20px;
    border-radius: 8px;
    box-shadow: 0 2px 6px rgba(96, 165, 250, 0.3);
    transition: all 0.25s ease-in-out;
    text-align: center;
    font-size: 0.9rem;
    font-weight: 500;
    border: none;
    cursor: pointer;
    font-family: 'Roboto', sans-serif;
}

.ctc-copy-button:hover {
    background-color: #3B82F6;
    color: #F3F4F6;
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(59, 130, 246, 0.35);
}

.ctc-copy-button.copied {
    background-color: #34D399;
    color: #F3F4F6;
    border: 1px solid #10B981;
    transform: scale(1.03);
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.25);
}

.ctc-copy-button.copy-error {
    background-color: #34D399;
    color: #F3F4F6;
    border: 1px solid #10B981;
    transform: scale(1.03);
    box-shadow: 0 4px 10px rgba(16, 185, 129, 0.25);
}

.ctc-qr-title {
    font-weight: 700;
    font-size: 1.125rem;
    color: #1f2937;
    margin-bottom: 1rem;
}

.ctc-qr-code {
    width: 300px;
    height: 300px;
    margin-bottom: 1rem;
    border-radius: 0.5rem;
    background-color: #ffffff;
}

.ctc-qr-link {
    color: #9ca3af;
    text-decoration: none;
    transition: color 0.2s ease;
    word-break: break-all;
}

.ctc-qr-link:hover {
    color: #6b7280;
}

.ctc-qr-link .https-part {
    color: #16a34a;
}

.ctc-qr-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.ctc-qr-modal:not(.hidden) {
    opacity: 1;
    visibility: visible;
}

.ctc-qr-modal-content {
    background-color: #ffffff;
    border-radius: 1rem;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    animation: modalFadeIn 0.3s ease-out;
    direction: rtl;
    text-align: right;
}

.ctc-qr-close-button {
    background-color: #60A5FA;
    color: #F3F4F6;
    padding: 0.75rem 2rem;
    border-radius: 0.5rem;
    box-shadow: 0 4px 8px rgba(96, 165, 250, 0.3);
    transition: all 0.4s ease;
    text-align: center;
    border: none;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    margin-top: 1rem;
}

.ctc-qr-close-button:hover {
    background-color: #3B82F6;
    transform: scale(1.05);
    box-shadow: 0 6px 12px rgba(59, 130, 246, 0.4);
    color: #F3F4F6;
}

.ctc-qr-modal-body {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.payment_methods li img {
    margin-inline-start: 5px;
    margin-inline-end: 5px;
    max-height: none;
}

.ctc-account-details.hidden, .ctc-general-fields.hidden, .ctc-qr-fields.hidden {
    display: none;
}

.ctc-account-details, .ctc-general-fields, .ctc-qr-fields {
    transition: opacity 0.3s ease, transform 0.3s ease;
    opacity: 1;
    transform: translateY(0);
}

.ctc-account-details.animate-details, .ctc-general-fields.animate-details, .ctc-qr-fields.animate-details {
    opacity: 1;
    transform: translateY(0);
}

.payment_methods .payment_box p:last-child {
    margin: 22px 4px 7px 1px !important;
}
.payment_methods .payment_box {
    --wd-tags-mb: 10px;
    position: relative;
    margin-top: 15px;
    padding: 5px;
    background-color: var(--bgcolor-white);
    box-shadow: 1px 1px 2px rgba(0, 0, 0, 0.05);
    border-radius: var(--wd-brd-radius);
}
/* پایه */
.ctc-select-text {
  font-weight: 700;           /* وزن 700 */
  font-size: 15px;           /* اندازه 15px */
  line-height: 1.35;         /* راهنمایی برای فاصله‌ی عمودی بهتر */
  color: #0f172a;            /* رنگ متن (قابل تغییر) */
  display: inline-block;     /* یا block / flex بسته به نیاز */
  vertical-align: middle;
  overflow: hidden;
  text-overflow: ellipsis;   /* ... برای متن‌های بلند */
  max-width: 100%;           /* جلوگیری از بیرون‌زدن در ظرف */
  letter-spacing: 0.2px;     /* کمی فاصله بین حروف برای خوانایی */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  cursor: default;
   margin: 15px;         /* اگر قابل انتخاب نیست، تغییر دهید */
}

.ctc-bottom-text  {
  font-weight: 600;
  font-size: 15px;
  margin: 15px;
}

.ctc-top-text
{
  font-weight: 600;
  font-size: 15px;
  margin: 15px;
}
