/* ============================================
   宮古島コンシェルジュ — スタイルシート
   カラーパレット: 沖縄の海グラデーション
   ============================================ */

/* --- Design Tokens --- */
:root {
    --color-ocean-deep: #023E8A;
    --color-ocean-mid: #0077B6;
    --color-ocean-light: #00B4D8;
    --color-ocean-pale: #90E0EF;
    --color-ocean-foam: #CAF0F8;

    --color-sand: #F8F4E8;
    --color-coral: #FF6B6B;
    --color-sunset: #FF9F43;

    --color-score-excellent: #00C853;
    --color-score-good: #2196F3;
    --color-score-fair: #FFC107;
    --color-score-poor: #F44336;

    --color-congestion-low: #4CAF50;
    --color-congestion-mid: #FF9800;
    --color-congestion-high: #F44336;

    --color-text: #1A1A2E;
    --color-text-light: #4A4A6A;
    --color-text-white: #FFFFFF;
    --color-text-muted: rgba(255, 255, 255, 0.7);

    --font-body: 'Noto Sans JP', 'Hiragino Sans', sans-serif;
    --font-display: 'Outfit', 'Noto Sans JP', sans-serif;

    --radius-sm: 8px;
    --radius-md: 16px;
    --radius-lg: 24px;
    --radius-xl: 32px;

    --shadow-card: 0 4px 24px rgba(0, 0, 0, 0.12);
    --shadow-card-hover: 0 8px 40px rgba(0, 0, 0, 0.2);
    --shadow-fab: 0 6px 20px rgba(0, 119, 182, 0.4);

    --glass-bg: rgba(255, 255, 255, 0.12);
    --glass-border: rgba(255, 255, 255, 0.2);
    --glass-bg-strong: rgba(255, 255, 255, 0.18);

    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}

/* --- Reset & Base --- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-body);
    color: var(--color-text-white);
    background: linear-gradient(135deg, var(--color-ocean-deep) 0%, #0353A4 50%, var(--color-ocean-mid) 100%);
    min-height: 100vh;
    min-height: 100dvh;
    padding-bottom: env(safe-area-inset-bottom);
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background:
        radial-gradient(ellipse at 20% 80%, rgba(0, 180, 216, 0.15) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 20%, rgba(144, 224, 239, 0.1) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* --- Weather Bar --- */
/* --- Header & Weather Bar --- */
.header {
    background: var(--color-ocean-deep);
    padding: 12px 16px;
    padding-top: calc(12px + env(safe-area-inset-top));
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    color: var(--color-text-white);
}

.header__flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    margin-bottom: 12px;
}

.header__main {
    display: flex;
    align-items: center;
    gap: 12px;
}

.concierge-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--color-ocean-pale);
}

.header__title {
    font-family: var(--font-display);
    font-size: 1.5rem;
    font-weight: 800;
    margin: 0;
    letter-spacing: -0.01em;
}

.weather-bar {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 6px;
    flex-shrink: 0;
}

.wb-update-time {
    font-size: 0.65rem;
    opacity: 0.8;
    color: var(--color-ocean-pale);
    font-weight: 600;
}

.wb-row {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    width: 100%;
}

.wb-row--main {
    font-weight: 700;
    font-size: 0.9rem;
}

.wb-row--sea {
    font-size: 0.8rem;
    color: var(--color-text-white);
    background: rgba(255, 255, 255, 0.15);
    padding: 4px 12px;
    border-radius: 20px;
    border: 1px solid var(--glass-border);
}

.wb-item {
    display: flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}

/* --- Hourly Weather Scroll --- */
.weather-hourly-scroll {
    display: flex;
    overflow-x: auto;
    padding: 6px 12px;
    gap: 12px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin; /* Firefox */
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}
.weather-hourly-scroll::-webkit-scrollbar {
    height: 3px;
    display: block; /* 微細に見せる */
}
.weather-hourly-scroll::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
}

.hourly-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--color-text-white);
    min-width: 54px;
    gap: 2px;
    position: relative;
    padding-top: 4px;
}

.hourly-item .h-date {
    position: absolute;
    top: -10px;
    left: 0;
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--color-ocean-pale);
    white-space: nowrap;
}

.h-row-main {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    font-weight: 700;
}

.h-row-sub {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.65rem;
    opacity: 0.8;
}

.hourly-item .h-icon { font-size: 0.9rem; }
.hourly-item .h-temp { font-weight: 600; color: #fff; }
.hourly-item .h-wind { font-size: 0.6rem; }

/* --- Island Grouping & Filters --- */
.island-filter-container {
    display: flex;
    overflow-x: auto;
    gap: 10px;
    padding: 16px 0;
    margin-bottom: 20px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.island-filter-container::-webkit-scrollbar {
    display: none;
}

.filter-btn, .jump-btn {
    padding: 10px 20px;
    border-radius: 30px;
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
    color: var(--color-text-white);
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    transition: all var(--transition-bounce);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.filter-btn:hover, .jump-btn:hover {
    background: var(--glass-bg-strong);
    transform: translateY(-2px);
}

.filter-btn.active {
    background: linear-gradient(135deg, var(--color-ocean-light), var(--color-ocean-mid));
    border-color: transparent;
    box-shadow: var(--shadow-fab);
}

/* 個別ページ用のジャンプタブ（固定表示） */
.jump-tabs-container {
    position: sticky;
    top: 140px; /* ウェザーバーの下あたり */
    z-index: 900;
    display: flex;
    justify-content: center;
    gap: 8px;
    padding: 8px;
    background: rgba(2, 62, 138, 0.8);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid var(--glass-border);
    margin-top: -20px;
    margin-bottom: 20px;
}

.jump-btn {
    padding: 6px 14px;
    font-size: 0.8rem;
    background: rgba(255, 255, 255, 0.1);
}

.island-group {
    margin-bottom: 32px;
}

.island-group-title {
    grid-column: 1 / -1; /* グリッドの全幅を占有する */
    font-family: var(--font-display);
    font-size: 1.1rem;
    font-weight: 800;
    color: var(--color-text-white);
    padding: 10px 16px;
    background: linear-gradient(90deg, rgba(0, 180, 216, 0.3), transparent);
    border-left: 6px solid var(--color-ocean-light);
    margin: 40px 0 24px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    border-radius: 0 8px 8px 0;
    scroll-margin-top: 200px; /* ジャンプ時の余白 */
}

/* --- Responsive Adjustments --- */
@media (max-width: 600px) {
    .header__flex {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .weather-bar {
        width: 100%;
        align-items: flex-start;
    }
    .header__title {
        font-size: 1.1rem;
    }
    .wb-row {
        gap: 6px 10px;
        justify-content: flex-start;
    }
    .wb-row--main {
        font-size: 0.82rem;
    }
    .wb-row--sea {
        font-size: 0.72rem;
        padding: 4px 8px;
    }
}

/* --- Main --- */
.main {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px 16px 100px;
}

/* --- Section --- */
.section {
    margin-bottom: 36px;
}

.section__title {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    font-family: var(--font-display);
    font-size: 1.4rem;
    font-weight: 800;
    margin-bottom: 24px;
    color: var(--color-text-white);
    gap: 12px;
    flex-wrap: wrap;
}

.btn-title-more {
    font-size: 0.82rem;
    font-weight: 600;
    color: var(--color-ocean-pale);
    text-decoration: none;
    padding: 6px 14px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    transition: all var(--transition);
    white-space: nowrap;
}

.btn-title-more:hover {
    background: var(--glass-bg-strong);
    color: #fff;
    transform: translateX(4px);
}

.section__title-text {
    display: flex;
    align-items: center;
    gap: 8px;
}

.section__icon {
    font-size: 1.3em;
}

/* --- Top3 Row (TOP Page) --- */
.top3-row {
    display: flex;
    gap: 16px;
    align-items: stretch;
    margin-bottom: 32px;
}
.top3-row .card-grid {
    flex: 1;
    margin-bottom: 0;
}

.btn-more-side {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: var(--color-ocean-deep);
    color: var(--color-white);
    text-decoration: none;
    padding: 24px 16px;
    border-radius: var(--radius-md);
    font-weight: 700;
    font-size: 1rem;
    transition: background 0.2s, transform 0.2s;
    text-align: center;
    line-height: 1.4;
    min-width: 80px;
    white-space: nowrap;
}
.btn-more-side:hover {
    background: var(--color-ocean-mid);
    transform: translateX(4px);
}
.btn-more-side .arrow {
    margin-top: 8px;
    font-size: 1.4rem;
}

@media (max-width: 768px) {
    .top3-row {
        flex-direction: column;
    }
    .btn-more-side {
        width: 100%;
        padding: 16px;
        flex-direction: row;
        gap: 8px;
    }
    .btn-more-side .arrow {
        margin-top: 0;
    }
}

/* --- Buttons --- */
.more-btn-container {
    text-align: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px dashed var(--color-sand);
}
.btn-more, .spot-card__tag {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: var(--color-ocean-foam);
    color: var(--color-ocean-deep);
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 12px;
    white-space: nowrap;
}
.spot-card__tag i {
    font-size: 1.1em;
}

/* Actions */
.btn-more {
    display: inline-block;
    padding: 10px 24px;
    background: var(--color-ocean-deep);
    color: var(--color-white);
    text-decoration: none;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 600;
    transition: background 0.2s, transform 0.2s;
}
.btn-more:hover {
    background: var(--color-ocean-mid);
    transform: translateY(-2px);
}
.btn-back-top {
    display: inline-block;
    padding: 14px 28px;
    background: #FF9800; /* 視認性の高いオレンジ */
    color: #fff;
    text-decoration: none;
    border-radius: 30px;
    font-size: 1.1rem;
    font-weight: 800;
    letter-spacing: 0.05em;
    box-shadow: 0 4px 6px rgba(0,0,0,0.15);
    transition: background 0.2s, transform 0.2s, box-shadow 0.2s;
    border: none;
}
.btn-back-top:hover {
    background: #F57C00;
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(0,0,0,0.2);
    color: #fff;
}
.page-header {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}

/* --- Subcategory Filter (Restaurant Page) --- */
.subcategory-filter {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 32px;
    padding: 8px;
    background: var(--glass-bg-strong);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 40px;
    border: 1px solid var(--glass-border);
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 500px) {
    .subcategory-filter {
        border-radius: 20px;
        width: 100%;
    }
}

/* --- Card Link Wrapper --- */
a.spot-card-link {
    text-decoration: none;
    color: inherit;
    display: block;
    height: 100%;
}
a.spot-card-link:hover .spot-card {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

/* --- TOP3 Grid (Deprecating old specific top3 grid for now) --- */
.top3-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

@media (max-width: 768px) {
    .top3-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
}

/* --- TOP3 Card --- */
.top3-card {
    background: var(--glass-bg-strong);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    position: relative;
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition);
    cursor: pointer;
    text-decoration: none;
    color: inherit;
    display: flex;
    flex-direction: column;
}

.top3-card__image-container {
    width: 100%;
    aspect-ratio: 16 / 6;
    max-height: 140px;
    overflow: hidden;
    position: relative;
}

.top3-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s ease;
}

.top3-card:hover .top3-card__image {
    transform: scale(1.08);
}

.top3-card__content {
    padding: 12px 16px; /* パディングを詰める */
    flex: 1;
}

.top3-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--color-ocean-light), var(--color-ocean-pale));
}

.top3-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card-hover);
}

.top3-card:active {
    transform: scale(0.98);
}

.top3-card__rank {
    position: absolute;
    top: 12px;
    right: 16px;
    font-family: var(--font-display);
    font-size: 2.4rem;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.1);
    line-height: 1;
}

.top3-card__score {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    font-size: 1.3rem;
    font-weight: 900;
    margin-bottom: 8px;
}

.top3-card__name {
    font-family: var(--font-display);
    font-size: 1.2rem;
    font-weight: 700;
    margin-bottom: 6px;
    line-height: 1.3;
}

.top3-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.top3-card__detail {
    font-size: 0.8rem;
    color: var(--color-text-muted);
    line-height: 1.5;
}

/* --- Card Grid --- */
.card-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}

@media (max-width: 800px) {
    .card-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 500px) {
    .card-grid {
        grid-template-columns: 1fr;
    }
}

/* --- Spot Card --- */
.spot-card {
    background: var(--glass-bg);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    transition: transform var(--transition), box-shadow var(--transition);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.spot-card__image-container {
    width: 100%;
    aspect-ratio: 16 / 7;
    max-height: 130px;
    overflow: hidden;
    position: relative; /* 子の星評価の基準点 */
}

.spot-card__image-placeholder {
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(255,255,255,0.03) 0%, rgba(255,255,255,0.08) 100%);
}

.spot-card__image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s ease;
}

.spot-card:hover .spot-card__image {
    transform: scale(1.05);
}

.spot-card:hover .spot-card__score-badge.average { background: #FFC107; color: #333; }
.spot-card__score-badge.poor {
    background: #FF5252;
    border-radius: 12px; /* カプセル型に変更して文字が飛び出さないように */
    padding: 4px 10px;
    width: auto;
    height: auto;
    font-size: 0.75rem;
    letter-spacing: 0;
}

/* Attributes / Tags */
.spot-card__features {
    transform: translateY(-2px);
    box-shadow: var(--shadow-card);
}

.spot-card__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
}

.spot-card__name {
    font-family: var(--font-display);
    font-size: 0.95rem; /* 少し小さく */
    font-weight: 700;
}

.spot-card__distance {
    font-size: 0.62rem;
    color: var(--color-ocean-pale);
    opacity: 0.9;
    font-weight: 500;
}

.v-flex {
    display: flex;
    flex-direction: column;
}

.spot-card__score-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 32px; /* 最小幅を維持 */
    width: auto;     /* テキスト量に応じて拡大 */
    height: 32px;
    padding: 0 10px; /* 左右に余白を追加 */
    border-radius: 16px; /* カプセル型（Pill）に統一 */
    font-size: 0.85rem; /* テキスト用には少しサイズを調整 */
    font-weight: 800;
    flex-shrink: 0;
    white-space: nowrap; /* 改行を絶対にさせない */
}

.spot-card__tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.spot-card__content {
    padding: 12px;
    flex: 1;
    display: flex;
    flex-direction: column;
}
.spot-card__desc {
    font-size: 0.72rem;
    color: var(--color-text-muted);
    margin-bottom: 10px;
    line-height: 1.35;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    flex: 1; /* 内容に関わらずフッターを下に押し下げる */
    min-height: 2.7em; /* 2行分の高さを最低限確保 */
}

.spot-card__rating {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(4px);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8rem;
    letter-spacing: 2px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
    z-index: 5;
}

.spot-card__hours {
    font-size: 0.7rem;
    color: var(--color-ocean-pale);
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 4px;
    font-weight: 500;
}

.hours-icon {
    font-style: normal;
    font-size: 0.8rem;
}

.spot-card__footer {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-top: auto;
    padding-top: 8px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.congestion-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
}

.congestion-label {
    font-size: 0.62rem;
    color: var(--color-ocean-pale);
    opacity: 0.8;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.congestion-status {
    font-size: 0.68rem;
    font-weight: 700;
    color: #fff;
}

.h-flex-bet {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    width: 100%;
}

/* --- Tags & Badges --- */
.tag {
    display: inline-flex;
    align-items: center;
    gap: 3px;
    padding: 3px 8px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 600;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    white-space: nowrap;
}

.tag--windshield {
    background: rgba(0, 200, 83, 0.2);
    border-color: rgba(0, 200, 83, 0.4);
    color: #69F0AE;
}

.tag--congestion-low {
    color: var(--color-congestion-low);
}
.tag--congestion-mid {
    color: var(--color-congestion-mid);
}
.tag--congestion-high {
    color: var(--color-congestion-high);
}

.tag--island {
    background: rgba(144, 224, 239, 0.15);
    border-color: rgba(144, 224, 239, 0.3);
}

/* Score badge colors */
.score--excellent {
    background: var(--color-score-excellent);
    color: #fff;
}
.score--good {
    background: var(--color-score-good);
    color: #fff;
}
.score--fair {
    background: var(--color-score-fair);
    color: #333;
}
.score--poor {
    background: var(--color-score-poor);
    color: #fff;
}

/* --- Google Maps Button --- */
.btn-maps {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--color-text-white);
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    text-decoration: none;
    transition: background var(--transition);
    white-space: nowrap;
}

.btn-maps:hover {
    background: rgba(255, 255, 255, 0.2);
}

.btn-maps:active {
    transform: scale(0.96);
}

/* --- Congestion Bar --- */
.congestion-bar {
    width: 100%;
    height: 8px;
    border-radius: 4px;
    background: rgba(255, 255, 255, 0.2);
    overflow: hidden;
    max-width: 120px;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.congestion-bar__fill {
    height: 100%;
    border-radius: 3px;
    transition: width var(--transition);
}

.congestion-bar__fill--low {
    background: var(--color-congestion-low);
}
.congestion-bar__fill--mid {
    background: var(--color-congestion-mid);
}
.congestion-bar__fill--high {
    background: var(--color-congestion-high);
}

/* --- FAB --- */
.fab {
    position: fixed;
    bottom: 24px;
    right: 24px;
    bottom: calc(24px + env(safe-area-inset-bottom));
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--color-ocean-light), var(--color-ocean-mid));
    color: #fff;
    font-size: 1.6rem;
    font-weight: 700;
    border: none;
    cursor: pointer;
    box-shadow: var(--shadow-fab);
    z-index: 50;
    transition: transform var(--transition-bounce), box-shadow var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.fab:hover {
    transform: scale(1.1);
    box-shadow: 0 8px 30px rgba(0, 119, 182, 0.5);
}

.fab:active {
    transform: scale(0.95);
}

/* --- Modal --- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 200;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    animation: fadeIn 0.2s ease;
}

.modal-overlay[hidden] {
    display: none;
}

.modal {
    background: linear-gradient(135deg, #0D1B2A 0%, #1B2838 100%);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-xl);
    padding: 28px;
    width: 100%;
    max-width: 520px;
    max-height: 90vh;
    overflow-y: auto;
    animation: slideUp 0.3s var(--transition);
}

.modal__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal__title {
    font-family: var(--font-display);
    font-size: 1.3rem;
    font-weight: 700;
}

.modal__close {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--glass-border);
    background: var(--glass-bg);
    color: #fff;
    font-size: 1.2rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background var(--transition);
}

.modal__close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* --- Form --- */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--color-text-muted);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--glass-border);
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
    font-family: var(--font-body);
    font-size: 0.95rem;
    transition: border-color var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--color-ocean-light);
}

.form-group select option {
    background: #1B2838;
    color: #fff;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.form-actions {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

/* --- Buttons --- */
.btn {
    padding: 12px 24px;
    border-radius: var(--radius-md);
    font-family: var(--font-display);
    font-size: 0.95rem;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: transform var(--transition), opacity var(--transition);
}

.btn:active {
    transform: scale(0.97);
}

.btn--primary {
    background: linear-gradient(135deg, var(--color-ocean-light), var(--color-ocean-mid));
    color: #fff;
    flex: 1;
}

.btn--primary:hover {
    opacity: 0.9;
}

.btn--secondary {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    color: #fff;
}

.btn--secondary:hover {
    background: var(--glass-bg-strong);
}

/* --- Animations --- */
@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes cardEnter {
    from { opacity: 0; transform: translateY(12px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.spot-card,
.top3-card {
    animation: cardEnter 0.4s ease backwards;
}

.spot-card:nth-child(1), .top3-card:nth-child(1) { animation-delay: 0.05s; }
.spot-card:nth-child(2), .top3-card:nth-child(2) { animation-delay: 0.1s; }
.spot-card:nth-child(3), .top3-card:nth-child(3) { animation-delay: 0.15s; }
.spot-card:nth-child(4) { animation-delay: 0.2s; }
.spot-card:nth-child(5) { animation-delay: 0.25s; }
.spot-card:nth-child(6) { animation-delay: 0.3s; }
.spot-card:nth-child(7) { animation-delay: 0.35s; }
.spot-card:nth-child(8) { animation-delay: 0.4s; }

/* --- Responsive --- */
@media (max-width: 600px) {
    .weather-bar__inner {
        font-size: 0.75rem;
        gap: 6px;
    }

    .wb-row {
        gap: 6px;
    }

    .weather-bar__item {
        padding: 3px 8px;
    }

    .section__title {
        font-size: 1.2rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .top3-card {
        padding: 18px 16px;
    }

    .modal {
        padding: 20px;
        border-radius: var(--radius-lg);
    }
}

/* iPad向け */
@media (min-width: 768px) and (max-width: 1024px) {
    .top3-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .card-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ラージディスプレイ */
@media (min-width: 1025px) {
    .card-grid {
        grid-template-columns: repeat(3, 1fr);
        align-items: stretch; /* カードの高さを揃える */
    }
}

/* --- Empty State --- */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: var(--color-text-muted);
    font-size: 0.9rem;
}
