/* === 認証ページ専用スタイル === */

/* ログイン/登録ページ共通レイアウト */
.auth-wrapper {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 200px);
    padding: 40px 20px;
}

.auth-card {
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(30px) saturate(180%);
    border-radius: 24px;
    border: 1px solid rgba(212, 175, 55, 0.2);
    box-shadow:
        0 20px 60px rgba(0, 0, 0, 0.3),
        0 4px 12px rgba(212, 175, 55, 0.1);
    width: 100%;
    max-width: 520px;
    padding: 48px 40px;
    animation: auth-card-appear 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.auth-card.wide {
    max-width: 700px;
}

@keyframes auth-card-appear {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.97);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* ヘッダーエリア */
.auth-header {
    text-align: center;
    margin-bottom: 36px;
}

.auth-header .auth-icon {
    width: 72px;
    height: 72px;
    background: linear-gradient(135deg, #d4af37 0%, #f4e4c1 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 8px 24px rgba(212, 175, 55, 0.35);
    animation: icon-pulse 2s ease-in-out infinite alternate;
}

@keyframes icon-pulse {
    0% { box-shadow: 0 8px 24px rgba(212, 175, 55, 0.35); }
    100% { box-shadow: 0 12px 36px rgba(212, 175, 55, 0.55); }
}

.auth-header .auth-icon i {
    font-size: 1.8rem;
    color: #1a1625;
}

.auth-header h2 {
    font-size: 1.6rem;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 8px;
}

.auth-header p {
    color: #6b7280;
    font-size: 0.92rem;
    line-height: 1.6;
}

/* フォームグループ */
.auth-form .form-group {
    margin-bottom: 20px;
}

.auth-form .form-group label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

.auth-form .form-group label .required-mark {
    color: #ef4444;
    margin-left: 4px;
    font-size: 0.85rem;
}

.auth-form .form-group label .optional-mark {
    color: #9ca3af;
    font-size: 0.8rem;
    margin-left: 6px;
    font-weight: 400;
}

.auth-form .form-input {
    width: 100%;
    padding: 13px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 0.95rem;
    transition: all 0.25s ease;
    background: #f9fafb;
    color: #1a1a2e;
    font-weight: 500;
    box-sizing: border-box;
}

.auth-form .form-input:focus {
    outline: none;
    border-color: var(--gold, #d4af37);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.12);
}

.auth-form .form-input::placeholder {
    color: #9ca3af;
    font-weight: 400;
}

.auth-form select.form-input {
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml;charset=US-ASCII,%3Csvg%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%20width%3D%22292.4%22%20height%3D%22292.4%22%3E%3Cpath%20fill%3D%22%23d4af37%22%20d%3D%22M287%2069.4a17.6%2017.6%200%200%200-13-5.4H18.4c-5%200-9.3%201.8-12.9%205.4A17.6%2017.6%200%200%200%200%2082.2c0%205%201.8%209.3%205.4%2012.9l128%20127.9c3.6%203.6%207.8%205.4%2012.8%205.4s9.2-1.8%2012.8-5.4L287%2095c3.5-3.5%205.4-7.8%205.4-12.8%200-5-1.9-9.2-5.5-12.8z%22%2F%3E%3C%2Fsvg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 12px;
    padding-right: 40px;
    cursor: pointer;
}

/* パスワード強度インジケーター */
.password-strength {
    margin-top: 8px;
    height: 4px;
    background: #e5e7eb;
    border-radius: 2px;
    overflow: hidden;
}

.password-strength .strength-bar {
    height: 100%;
    width: 0%;
    border-radius: 2px;
    transition: all 0.4s ease;
}

.password-strength .strength-bar.weak { width: 33%; background: #ef4444; }
.password-strength .strength-bar.medium { width: 66%; background: #f59e0b; }
.password-strength .strength-bar.strong { width: 100%; background: #22c55e; }

.password-hint {
    font-size: 0.78rem;
    color: #9ca3af;
    margin-top: 6px;
}

/* セクション分割 */
.auth-section {
    margin-top: 28px;
    padding-top: 24px;
    border-top: 1px solid rgba(212, 175, 55, 0.15);
}

.auth-section-title {
    font-size: 1rem;
    font-weight: 700;
    color: #1a1a2e;
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
}

.auth-section-title i {
    color: #d4af37;
    font-size: 0.95rem;
}

/* 2カラムレイアウト（登録フォーム内） */
.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

@media (max-width: 600px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* 送信ボタン */
.auth-submit {
    width: 100%;
    padding: 15px;
    margin-top: 28px;
    font-size: 1.05rem;
    font-weight: 700;
    border: none;
    border-radius: 14px;
    background: linear-gradient(135deg, #d4af37 0%, #f4e4c1 100%);
    color: #1a1625;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 16px rgba(212, 175, 55, 0.35);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    letter-spacing: 0.02em;
}

.auth-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(212, 175, 55, 0.5);
}

.auth-submit:active {
    transform: translateY(0);
}

.auth-submit:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* エラーメッセージ */
.auth-error {
    background: rgba(239, 68, 68, 0.08);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-left: 4px solid #ef4444;
    color: #dc2626;
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    animation: shake 0.4s ease;
}

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

.auth-error i {
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* 成功メッセージ */
.auth-success {
    background: rgba(34, 197, 94, 0.08);
    border: 1px solid rgba(34, 197, 94, 0.3);
    border-left: 4px solid #22c55e;
    color: #16a34a;
    padding: 12px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.auth-success i {
    font-size: 1.1rem;
    flex-shrink: 0;
}

/* フッターリンク */
.auth-footer {
    text-align: center;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid #e5e7eb;
}

.auth-footer p {
    font-size: 0.9rem;
    color: #6b7280;
}

.auth-footer a {
    color: #d4af37;
    font-weight: 600;
    text-decoration: none;
    transition: color 0.2s;
}

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

/* ヘッダーナビ - ログイン状態表示 */
.nav-user-area {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-top: 12px;
    justify-content: center;
}

.nav-user-info {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--gold-light, #f4e4c1);
    font-size: 0.9rem;
}

.nav-user-info i {
    color: var(--gold, #d4af37);
}

.nav-user-info .user-name {
    font-weight: 600;
}

.btn-logout {
    padding: 6px 16px;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 50px;
    background: transparent;
    color: var(--gold-light, #f4e4c1);
    font-size: 0.82rem;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.25s;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-logout:hover {
    background: rgba(212, 175, 55, 0.15);
    border-color: rgba(212, 175, 55, 0.6);
    color: #d4af37;
}

.btn-login-nav {
    padding: 8px 20px;
    border: 1px solid rgba(212, 175, 55, 0.4);
    border-radius: 50px;
    background: rgba(212, 175, 55, 0.1);
    color: var(--gold-light, #f4e4c1);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
    cursor: pointer;
    transition: all 0.25s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}

.btn-login-nav:hover {
    background: rgba(212, 175, 55, 0.25);
    border-color: rgba(212, 175, 55, 0.6);
    transform: translateY(-1px);
}

/* レスポンシブ */
@media (max-width: 600px) {
    .auth-card {
        padding: 32px 24px;
        border-radius: 18px;
        margin: 10px;
    }

    .auth-card.wide {
        max-width: 100%;
    }

    .auth-header h2 {
        font-size: 1.35rem;
    }

    .auth-header .auth-icon {
        width: 60px;
        height: 60px;
    }

    .auth-header .auth-icon i {
        font-size: 1.5rem;
    }
}
