/* Forgot Password Page Styles - Production Ready */

/* --- Кроссбраузерный сброс --- */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
    margin: 0;
    padding: 0;
    border: 0;
    font-size: 100%;
    font: inherit;
    vertical-align: baseline;
    box-sizing: border-box;
}

/* HTML5 display-role reset for older browsers */
article, aside, details, figcaption, figure, 
footer, header, hgroup, menu, nav, section {
    display: block;
}

body {
    line-height: 1;
}

ol, ul {
    list-style: none;
}

blockquote, q {
    quotes: none;
}

blockquote:before, blockquote:after,
q:before, q:after {
    content: '';
    content: none;
}

table {
    border-collapse: collapse;
    border-spacing: 0;
}

/* --- END сброс --- */

:root {
    --primary-color: #4285f4;
    --primary-hover: #3367d6;
    --error-color: #d32f2f;
    --success-color: #2e7d32;
    --text-color: #333;
    --text-secondary: #666;
    --border-color: #ddd;
    --background-color: #f5f5f5;
    --card-background: #fff;
    --shadow: 0 2px 10px rgba(0,0,0,0.1);
}

html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    text-size-adjust: 100%;
    height: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
    background-color: var(--background-color);
    color: var(--text-color);
    background-image: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

*, *:before, *:after {
    box-sizing: inherit;
}

/* --- Кроссбраузерные placeholder --- */
::-webkit-input-placeholder { color: #aaa; opacity: 1; }
:-moz-placeholder { color: #aaa; opacity: 1; }
::-moz-placeholder { color: #aaa; opacity: 1; }
:-ms-input-placeholder { color: #aaa; opacity: 1; }
::placeholder { color: #aaa; opacity: 1; }

/* --- Кроссбраузерные кнопки и input --- */
input, select, textarea, button {
    font-family: inherit;
    font-size: inherit;
    color: inherit;
    background: none;
    border: none;
    outline: none;
    box-shadow: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

input[type="checkbox"] {
    -webkit-appearance: checkbox;
    -moz-appearance: checkbox;
    appearance: checkbox;
}

input[type="date"]::-webkit-inner-spin-button,
input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(0.5);
}

button, input[type="submit"], input[type="button"] {
    cursor: pointer;
}

button:disabled, input:disabled {
    cursor: not-allowed;
}

/* --- END кроссбраузерные кнопки и input --- */

/* --- Кроссбраузерные flex/grid --- */
.forgot-container, .form-group, .steps, .form-footer {
    display: -webkit-box;
    display: -ms-flexbox;
    display: flex;
}

.forgot-container, .form-group, .form-footer {
    -webkit-box-orient: vertical;
    -webkit-box-direction: normal;
    -ms-flex-direction: column;
    flex-direction: column;
}

.steps {
    -webkit-box-orient: horizontal;
    -webkit-box-direction: normal;
    -ms-flex-direction: row;
    flex-direction: row;
    -webkit-box-align: center;
    -ms-flex-align: center;
    align-items: center;
    -webkit-box-pack: justify;
    -ms-flex-pack: justify;
    justify-content: space-between;
}

/* --- END flex/grid --- */

/* --- Кроссбраузерные градиенты, box-shadow, border-radius --- */
.forgot-container, .step {
    -webkit-border-radius: 12px;
    border-radius: 12px;
    -webkit-box-shadow: var(--shadow);
    box-shadow: var(--shadow);
}

.step {
    -webkit-border-radius: 50%;
    border-radius: 50%;
}

/* --- END градиенты, box-shadow, border-radius --- */

/* Основные стили */
.forgot-container {
    background: var(--card-background);
    padding: 2.5rem;
    width: 100%;
    max-width: 420px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    animation: fadeIn 0.5s ease;
}

.forgot-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 4px;
    background: linear-gradient(90deg, var(--primary-color), var(--primary-hover));
}

.forgot-container:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
}

h1 {
    text-align: center;
    color: var(--text-color);
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
    font-weight: 600;
}

.description {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    line-height: 1.5;
}

.form-group {
    margin-bottom: 1.5rem;
    position: relative;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
    font-size: 0.95rem;
}

input {
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    background-color: var(--background-color);
}

input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(66, 133, 244, 0.2);
    background-color: var(--card-background);
}

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

button {
    width: 100%;
    padding: 0.85rem;
    background-color: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1rem;
    margin-top: 1.5rem;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

button:hover {
    background-color: var(--primary-hover);
    transform: translateY(-1px);
}

button:active {
    transform: translateY(0);
}

button:disabled {
    background-color: var(--border-color);
    cursor: not-allowed;
    transform: none;
}

.error {
    color: var(--error-color);
    margin-top: 1rem;
    text-align: center;
    padding: 0.75rem;
    border-radius: 8px;
    background-color: rgba(211, 47, 47, 0.1);
    display: none;
    font-size: 0.9rem;
}

.success {
    color: var(--success-color);
    margin-top: 1rem;
    text-align: center;
    padding: 0.75rem;
    border-radius: 8px;
    background-color: rgba(46, 125, 50, 0.1);
    display: none;
    font-size: 0.9rem;
}

.loading {
    display: none;
    text-align: center;
    margin-top: 1rem;
}

.loading::after {
    content: "";
    display: inline-block;
    width: 24px;
    height: 24px;
    border: 3px solid var(--primary-color);
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.form-footer {
    text-align: center;
    margin-top: 1.5rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.form-footer a {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.form-footer a:hover {
    color: var(--primary-hover);
    text-decoration: underline;
}

/* Индикатор этапов */
.steps {
    display: flex;
    justify-content: space-between;
    margin-bottom: 2rem;
    position: relative;
}

.steps::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--border-color);
    z-index: 1;
}

.step {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: var(--card-background);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-secondary);
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.step.active {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: scale(1.1);
}

.step.completed {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
    transform: scale(1.05);
}

/* Анимации */
@keyframes fadeIn {
    from { 
        opacity: 0; 
        transform: translateY(-10px); 
    }
    to { 
        opacity: 1; 
        transform: translateY(0); 
    }
}

/* Стили для уведомлений */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    border-radius: 8px;
    color: white;
    box-shadow: var(--shadow);
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

.notification.success {
    background-color: var(--success-color);
}

.notification.error {
    background-color: var(--error-color);
}

/* Адаптивность */
@media (max-width: 768px) {
    .forgot-container {
        width: 95%;
        padding: 2rem;
        margin: 1rem auto;
    }
    
    h1 {
        font-size: 1.6rem;
    }
    
    .description {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .forgot-container {
        width: 98%;
        padding: 1.5rem;
        margin: 0.5rem auto;
    }

    h1 {
        font-size: 1.5rem;
    }

    input {
        padding: 0.75rem;
    }

    button {
        padding: 0.75rem;
    }
    
    .steps {
        margin-bottom: 1.5rem;
    }
    
    .step {
        width: 25px;
        height: 25px;
        font-size: 0.8rem;
    }
}

/* Убираем мигающий курсор */
body, .forgot-container, form, .form-group, label {
    caret-color: transparent;
    user-select: none;
}

input, textarea, select {
    caret-color: auto;
    user-select: auto;
}

button {
    caret-color: transparent;
    user-select: none;
}

a {
    caret-color: transparent;
    user-select: none;
} 
