/**
 * GEAL Layout - ボトムナビ・グリッド・フッターレイアウト
 * （ヘッダー・サブバーは header.css に集約）
 */

/* ========== ボトムナビ ========== */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: calc(70px + env(safe-area-inset-bottom, 0px));
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background: #ffffff;
    border-top: 1px solid #f0f0f0;
    display: flex;
    justify-content: space-around;
    align-items: center;
    z-index: 9999;
    transition: transform 0.3s ease-in-out;
}

.nav-hidden {
    transform: translateY(100%);
}

.nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #6b7280;
    font-size: 10px;
    font-weight: 700;
}

.nav-item.active {
    color: #7c3aed;
}

.nav-item i {
    font-size: 20px;
    margin-bottom: 2px;
}

/* ボトムバー：カート通知バッジ（アイコンの左上に厳密に固定） */
.bottom-nav .nav-item {
    position: relative;
}

.bottom-nav .cart-badge {
    position: absolute !important;
    top: -4px !important;
    left: calc(50% - 28px) !important; /* アイコン(20px)左端 - バッジ(18px)幅 = 左上に密着 */
    width: 18px !important;
    height: 18px !important;
    min-width: 18px !important;
    max-width: 18px !important;
    flex-shrink: 0 !important;
    box-sizing: border-box !important;
    background: #ef4444 !important;
    color: white !important;
    font-size: 10px !important;
    font-weight: 700 !important;
    padding: 0 !important;
    border-radius: 50% !important;
    display: none;
    align-items: center !important;
    justify-content: center !important;
    overflow: hidden;
    z-index: 10 !important;
}

/* ========== ダッシュボードグリッド（ベースのみ。padding/max-widthはページ固有CSSで設定） ========== */
.dashboard-grid-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    margin: 0 auto;
    background-color: transparent;
}

/* ========== グローバルフッター ========== */
.global-footer {
    background-color: #000000;
    border-top: 1px solid rgba(168, 85, 247, 0.4);
    padding: 40px 0;
    margin-top: auto;
    width: 100%;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 24px;
}

.footer-nav {
    display: flex;
    gap: 32px;
    flex-wrap: wrap;
    justify-content: center;
}

.footer-nav a {
    color: #e4e4e7;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.3s ease;
}

.footer-nav a:hover {
    color: #a855f7;
}

.footer-copyright {
    color: #71717a;
    font-size: 0.8rem;
}

/* =============================================
   Dark Mode overrides for geal-layout
   ============================================= */
[data-theme="dark"] .bottom-nav {
    background: var(--geal-bg-secondary);
    border-top-color: var(--geal-border);
}

[data-theme="dark"] .nav-item {
    color: var(--geal-text-faint);
}

[data-theme="dark"] .nav-item.active {
    color: var(--geal-accent-light);
}
