/* css/auth.css */

.auth-main {
    min-height: calc(100vh - 70px); /* ヘッダーの高さを引く */
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem 1.5rem;
    background-color: var(--bg-color); /* common.css の背景色を利用 */
}

.auth-container {
    background: #fff;
    width: 100%;
    max-width: 480px;
    padding: 2.5rem;
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    border: 1px solid var(--border-subtle);
}

.auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.auth-header h1 {
    font-size: 1.8rem;
    color: var(--text-main);
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.auth-header p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

/* Google Button */
.btn-google {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.8rem;
    padding: 0.8rem;
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-google:hover {
    background: #f8fafc;
    border-color: #94a3b8;
}

.google-icon {
    width: 20px;
    height: 20px;
}

/* Divider */
.auth-divider {
    display: flex;
    align-items: center;
    text-align: center;
    margin: 1.5rem 0;
    color: #94a3b8;
    font-size: 0.85rem;
}

.auth-divider::before,
.auth-divider::after {
    content: "";
    flex: 1;
    border-bottom: 1px solid #e2e8f0;
}

.auth-divider span {
    padding: 0 1rem;
}

/* Form Styles */
.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.2rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
}

.form-field-hint {
    margin: 0;
    font-size: 0.8rem;
    line-height: 1.45;
    color: #64748b;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"] {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: 0.2s;
    outline: none;
    box-sizing: border-box;
}

.form-group input:focus {
    border-color: var(--color-main);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.password-input-wrap {
    position: relative;
    display: flex;
    align-items: center;
}

.password-input-wrap input {
    padding-right: 2.8rem;
}

.toggle-password {
    position: absolute;
    right: 1rem;
    color: #94a3b8;
    cursor: pointer;
    font-size: 1.1rem;
    transition: 0.2s;
}

.toggle-password:hover {
    color: var(--text-main);
}

/* Checkbox */
.form-checkbox {
    margin-top: 0.2rem;
}

.form-checkbox label {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    cursor: pointer;
}

.form-checkbox input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    margin-top: 2px;
    cursor: pointer;
    position: relative;
    flex-shrink: 0;
    transition: 0.2s;
}

.form-checkbox input[type="checkbox"]:checked {
    background-color: var(--color-main);
    border-color: var(--color-main);
}

.form-checkbox input[type="checkbox"]:checked::after {
    content: "\f00c"; /* FontAwesome Check Icon */
    font-family: "Font Awesome 6 Free";
    font-weight: 900;
    color: white;
    font-size: 10px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.checkbox-text {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.checkbox-text a {
    color: var(--color-main);
    text-decoration: none;
    font-weight: 500;
}

.checkbox-text a:hover {
    text-decoration: underline;
}

/* Alert Section (Strictly One Account) */
.auth-alert {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    background-color: #fff1f2; /* 薄い赤色背景 */
    color: #e11d48; /* ローズレッド（添付画像風） */
    padding: 0.8rem 1rem;
    border-radius: 8px;
    font-size: 0.85rem;
    font-weight: 600;
    border: 1px solid #ffe4e6;
}

/* Submit Button */
.btn-submit {
    margin-top: 0.5rem;
    background-color: var(--color-main);
    color: #fff;
    border: none;
    padding: 0.9rem;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: 0.3s;
}

.btn-submit:hover {
    background-color: #1d4ed8;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.2);
}

/* Auth Footer */
.auth-footer {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.auth-footer a {
    color: var(--color-main);
    font-weight: 600;
    text-decoration: none;
}

.auth-footer a:hover {
    text-decoration: underline;
}

.auth-links {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.8rem;
    margin-top: 2rem;
    font-size: 0.8rem;
    color: #94a3b8;
}

.auth-links a {
    color: #64748b;
    text-decoration: none;
}

.auth-links a:hover {
    color: var(--text-main);
}




/* =========================================
   ログインページ用 追加スタイル
========================================= */

/* ソーシャルボタン横並びレイアウト */
.social-btns-row {
    display: flex;
    gap: 1rem;
    width: 100%;
}

.btn-social-half {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.8rem;
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--text-main);
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-social-half:hover {
    background: #f8fafc;
    border-color: #94a3b8;
}

/* Appleアイコンの色・サイズ */
.btn-social-half i.fa-apple {
    font-size: 1.25rem;
    color: #000;
    margin-bottom: 2px;
}

/* 続けるボタンのアイコン調整 */
.btn-continue {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.btn-continue i {
    font-size: 0.9rem;
}




/* =========================================
   ボタンのローディングアニメーション用
========================================= */

.spinner {
    width: 18px;
    height: 18px;
    border: 2px solid #cbd5e1;
    border-top-color: var(--color-main);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

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

/* 読み込み中のボタン状態 */
.btn-google.loading {
    pointer-events: none; /* 連打防止 */
    opacity: 0.8;
    background-color: #f8fafc;
}