@import url('https://fonts.googleapis.com/css2?family=Heebo:wght@300;400;500;600;700&display=swap');

:root {
    --main-bg: #1a1a29; /* Dark background from dashboard */
    --card-bg: #2a2a3c; /* Card background color */
    --card-border: rgba(255, 255, 255, 0.05);
    --primary-text: #f0f2f5;
    --secondary-text: #a9b4c4;
    --heading-color: #ffffff;
    --accent-color: #8c68cd;
    --accent-hover: #9d7ad8;
    --input-bg: rgba(0, 0, 0, 0.25);
    --input-border: rgba(255, 255, 255, 0.1);
    --shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

/* EMERGENCY FIX: Force full-width layout on ALL pages */
html body .container,
html body .container-fluid,
html body .site-content,
html body .content-area,
html body .wrap,
html body #primary,
html body #main,
html body .entry-content,
html body .page-content,
html body .renew-crm-content-area,
html body .renew-crm-main-content,
html body #renew-crm-frontend-app,
html body div[class*="container"],
html body div[class*="wrap"],
html body div[class*="content"] {
  max-width: none !important;
  width: 100% !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
}

/* Force all divs to be full width */
html body div {
  max-width: none !important;
}

body.otp-page {
    background: linear-gradient(135deg, #1a1a29 0%, #2a2a3c 100%);
    font-family: 'Heebo', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    padding: 20px;
    direction: rtl;
    line-height: 1.6;
    color: var(--primary-text);
}

.otp-container {
    max-width: 420px;
    width: 100%;
    padding: 20px;
    animation: fadeIn 0.5s ease-out;
}

.otp-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    padding: 40px 35px;
    border-radius: 12px;
    box-shadow: var(--shadow);
    text-align: center;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

h2 {
    font-size: 24px;
    font-weight: 600;
    margin: 0 0 20px 0;
    color: var(--heading-color);
    position: relative;
    padding-bottom: 15px;
}

h2:after {
    content: '';
    position: absolute;
    bottom: 0;
    right: 0;
    width: 50px;
    height: 3px;
    background: var(--accent-color);
    border-radius: 3px;
}

p {
    color: var(--secondary-text);
    margin: 0 0 30px 0;
    font-weight: 400;
    font-size: 15px;
    line-height: 1.6;
}

.form-group {
    margin-bottom: 24px;
    text-align: right;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 500;
    color: var(--primary-text);
    font-size: 14px;
    transition: all 0.2s ease;
}

.form-group input {
    width: 100%;
    padding: 14px 16px;
    border: 1px solid var(--input-border);
    border-radius: 8px;
    font-size: 15px;
    box-sizing: border-box;
    background-color: var(--input-bg);
    color: var(--primary-text);
    font-family: 'Heebo', sans-serif;
    text-align: right;
    transition: all 0.2s ease-in-out;
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.form-group input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(140, 104, 205, 0.25);
    background-color: rgba(0, 0, 0, 0.3);
}

.form-group input::placeholder {
    color: var(--secondary-text);
}

.form-group input:focus {
    outline: none;
    border-color: var(--accent-color);
    background-color: rgba(0, 0, 0, 0.3);
}


.btn-primary {
    background-color: var(--accent-color);
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 14px 24px;
    width: 100%;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    margin: 8px 0 0 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(140, 104, 205, 0.3);
}

.btn-primary:hover {
    background-color: var(--accent-hover);
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(140, 104, 205, 0.4);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 1px 5px rgba(140, 104, 205, 0.3);
}

.btn-primary:disabled {
    background-color: #555;
    cursor: not-allowed;
    transform: translateY(0);
}


.otp-inputs-wrapper {
    margin: 30px 0 20px;
    opacity: 0;
    height: 0;
    overflow: hidden;
    transition: all 0.3s ease;
}

.otp-inputs-wrapper.visible {
    opacity: 1;
    height: auto;
    margin: 30px 0 20px;
}

.otp-inputs-wrapper label {
    display: block;
    margin-bottom: 15px;
    font-weight: 500;
    color: var(--primary-text);
    text-align: right;
}

.otp-inputs {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    direction: ltr;
    margin-top: 15px;
}

.otp-inputs input {
    flex: 1;
    max-width: 60px;
    height: 60px;
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    border: 1px solid var(--input-border);
    border-radius: 8px;
    background-color: var(--input-bg);
    color: var(--primary-text);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.1);
}

.otp-inputs input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px rgba(140, 104, 205, 0.25);
    background-color: rgba(0, 0, 0, 0.3);
    transform: translateY(-2px);
}


/* Animations */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Responsive */
@media (max-width: 480px) {
    .otp-card {
        padding: 30px 20px;
    }
    
    h2 {
        font-size: 22px;
    }
    
    .btn-primary {
        padding: 12px 16px;
        font-size: 15px;
    }
    
    .otp-inputs input {
        height: 50px;
        font-size: 20px;
    }
    
    .form-group input {
        padding: 12px 14px;
        font-size: 15px;
    }
}

/* Loading state */
.btn-primary.loading {
    pointer-events: none;
    opacity: 0.8;
}

.btn-primary.loading:after {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    margin: auto;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #fff;
    border-radius: 50%;
    animation: button-loading-spinner 0.7s linear infinite;
    opacity: 0;
    transition: opacity 0.2s;
}

.btn-primary.loading span {
    opacity: 0;
}

@keyframes button-loading-spinner {
    from { transform: rotate(0turn); }
    to { transform: rotate(1turn); }
}

/* Error state */
.error-shake {
    animation: shake 0.3s ease-in-out;
}

/* Success state */
.success-message {
    color: #4ade80;
    font-weight: 500;
    margin-top: 15px;
    display: none;
}

/* Error message */
.error-message {
    color: #f87171;
    font-size: 14px;
    margin-top: 8px;
    text-align: right;
    display: none;
}

/* Show/hide utility */
.hidden {
    display: none !important;
}