/* styles.css - コード削減版（色・装飾維持） */

/* 基本レイアウト */
body {
    background-color: #fffcf7;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='100' viewBox='0 0 100 100'%3E%3Cg fill-rule='evenodd'%3E%3Cg fill='%23ffcccc' fill-opacity='0.12'%3E%3Cpath d='M11 18c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7zm48 25c3.866 0 7-3.134 7-7s-3.134-7-7-7-7 3.134-7 7 3.134 7 7 7z'%3E%3C/path%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* 装飾アニメーション */
body:before, body:after {
    content: "✿";
    position: fixed;
    font-size: 40px;
    color: rgba(255, 153, 153, 0.1);
    animation: floating 15s infinite linear;
    z-index: -1;
}

body:before {
    top: 10%;
    left: 5%;
    animation-duration: 17s;
}

body:after {
    bottom: 15%;
    right: 7%;
    font-size: 45px;
    animation-delay: 5s;
    animation-duration: 22s;
}

@keyframes floating {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    25% { transform: translate(10px, 10px) rotate(5deg); }
    50% { transform: translate(0, 20px) rotate(0deg); }
    75% { transform: translate(-10px, 10px) rotate(-5deg); }
}

/* スティッキーヘッダー */
.sticky-header {
    position: sticky;
    top: 0;
    z-index: 100;
    width: 100%;
    padding-bottom: 10px;
    box-shadow: 0 3px 8px rgba(255, 153, 153, 0.15);
    display: flex;
    flex-direction: column;
    align-items: center;
    background-color: #fff8fa;
    background-image:
        radial-gradient(circle at 20% 20%, rgba(255, 204, 204, 0.15) 9px, transparent 9px),
        radial-gradient(circle at 80% 40%, rgba(255, 229, 204, 0.12) 7px, transparent 7px),
        linear-gradient(120deg, #fff8fa 0%, #ffecf1 100%);
    background-size: 110px 110px, 85px 85px, 100% 100%;
    background-position: 0 0, 40px 20px, 0 0;
}

.sticky-header::before {
    content: "🍵";
    position: absolute;
    top: 15px;
    right: 8%;
    font-size: 24px;
    opacity: 0.2;
    animation: gentle-float 8s infinite ease-in-out;
}

.sticky-header:after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 15%;
    right: 15%;
    height: 3px;
    background: linear-gradient(90deg,
        rgba(255,204,204,0) 0%,
        rgba(255,204,204,0.4) 20%,
        rgba(255,229,204,0.6) 50%,
        rgba(255,204,204,0.4) 80%,
        rgba(255,204,204,0) 100%);
    border-radius: 2px;
}

.sticky-header-inner {
    max-width: 800px;
    width: 100%;
    padding: 0 20px;
    box-sizing: border-box;
    text-align: center;
    position: relative;
    z-index: 2;
}

.sticky-header-inner::after {
    content: "✿";
    position: absolute;
    top: 8px;
    left: 5%;
    font-size: 14px;
    opacity: 0.15;
    color: #ffb3d1;
    animation: gentle-float 10s infinite ease-in-out reverse;
}

@keyframes gentle-float {
    0%, 100% { transform: translateY(0px) rotate(0deg); opacity: 0.2; }
    50% { transform: translateY(-5px) rotate(0deg); opacity: 0.15; }
}

/* タイトル */
h1, p {
    text-align: center;
    margin-top: 20px;
}

h1 {
    color: #006633;
    position: relative;
    display: inline-block;
    margin: 15px auto 20px;
    padding: 8px 15px;
    font-size: 1.8em;
    background: linear-gradient(to right, #e6f7e6, #ffffff, #e6f7e6);
    border-radius: 8px;
    box-shadow: 0 3px 10px rgba(0, 128, 0, 0.15);
    text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.8);
    border: 2px solid #4CAF50;
    transition: all 0.3s ease;
}

h1:before, h1:after {
    content: "✿";
    color: #ff0f0f;
    margin: 5px;
    font-size: 0.9em;
    vertical-align: top;
}

h1:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 128, 0, 0.2);
}

h1:hover i {
    transform: rotate(15deg);
}

#emoji {
    display: inline-block;
    transition: all 0.4s ease;
}

h1:hover #emoji {
    animation: cute-bounce 0.8s ease infinite alternate;
}

@keyframes cute-bounce {
    0% { transform: translateY(0) rotate(5deg); }
    50% { transform: translateY(-5px) rotate(-5deg); }
    100% { transform: translateY(0) rotate(5deg); }
}

/* 注意書きボックス */
.box18 {
    margin: 2em 0;
    position: relative;
    padding: 0.5em;
    border: 2px dashed #ffb380;
    border-radius: 15px;
    background-color: #fff5eb;
    box-shadow: 0 3px 6px rgba(255, 153, 51, 0.1);
    font-size: 0.8em;
    overflow: hidden;
}

.box18:after {
    content: '✿';
    position: absolute;
    top: -10px;
    right: 15px;
    color: #ff9966;
    font-size: 28px;
    transform: rotate(5deg);
    text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.8);
}

.box18:before {
    content: '✿';
    position: absolute;
    bottom: -5px;
    left: 15px;
    color: #ffb380;
    font-size: 22px;
    transform: rotate(-10deg);
    opacity: 0.8;
}

.box18 p {
    margin: 0;
    color: #664400;
    line-height: 1.6;
    position: relative;
    z-index: 2;
}

.flower {
    position: absolute;
    font-size: 20px;
    z-index: 1;
}

.flower1 {
    top: 40%;
    right: 10%;
    color: #ffaa77;
    font-size: 22px;
    transform: rotate(10deg);
    opacity: 0.7;
}

.flower2 {
    bottom: 50%;
    right: 85%;
    color: #ffcc99;
    font-size: 18px;
    transform: rotate(-8deg);
    opacity: 0.6;
}

/* プレーヤー部分 */
#player-container {
    background-color: #fff9f4;
    padding: 12px 15px;
    border-radius: 20px;
    margin-bottom: 0;
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 5px 15px rgba(255, 153, 153, 0.2);
    border: 2px solid #ffcccc;
    width: 100%;
    position: relative;
    overflow: hidden;
}

#player-container:before {
    content: "";
    position: absolute;
    top: -15px;
    left: -15px;
    width: 30px;
    height: 30px;
    background-color: #ffcccc;
    border-radius: 50% 50% 0 50%;
    transform: rotate(45deg);
    z-index: 0;
}

#player-container:after {
    content: "";
    position: absolute;
    top: -15px;
    right: -15px;
    width: 30px;
    height: 30px;
    background-color: #ffcccc;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    z-index: 0;
}

.paw-print {
    position: absolute;
    opacity: 0.1;
    z-index: 0;
}

.paw1 {
    bottom: 5px;
    right: 5px;
    font-size: 20px;
    transform: rotate(30deg);
}

.paw2 {
    top: 10px;
    left: 30px;
    font-size: 16px;
    transform: rotate(-20deg);
}

/* プレーヤーコントロール */
#player-controls {
    display: flex;
    align-items: center;
    z-index: 1;
    margin-right: 10px;
}

#player-controls button {
    background: #fff;
    border: none;
    font-size: 18px;
    cursor: pointer;
    color: #ff9999;
    padding: 8px;
    margin-right: 8px;
    border-radius: 50%;
    box-shadow: 0 3px 8px rgba(255, 153, 153, 0.3);
    transition: all 0.3s ease;
    width: 36px;
    height: 36px;
    display: flex;
    justify-content: center;
    align-items: center;
}

#player-controls button:hover {
    background-color: #ffeeee;
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(255, 153, 153, 0.4);
}

#player-controls button:active {
    transform: translateY(1px);
}

#play-pause-btn:after {
    content: "😸";
    position: absolute;
    font-size: 8px;
    bottom: 2px;
    right: 2px;
    opacity: 0.7;
}

/* 情報表示エリア */
#now-playing {
    flex: 1;
    font-size: 14px;
    color: #996666;
    margin: 0 10px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 200px;
}

#current-audio-name {
    font-weight: bold;
    color: #ff6699;
    display: inline-block;
}

/* 時間表示 */
#time-display {
    color: #996666;
    font-size: 13px;
    font-family: 'Segoe UI', Tahoma, sans-serif;
    margin: 0 10px;
    white-space: nowrap;
}

#current-time, #total-time {
    font-weight: bold;
    color: #ff6699;
    background-color: #fff;
    padding: 2px 5px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(255, 153, 153, 0.3);
}

/* 音量コントロール */
#volume-control {
    display: flex;
    align-items: center;
    z-index: 1;
    margin-left: auto;
}

#volume-control i {
    color: #ff9999;
    margin: 0 5px;
    font-size: 14px;
    animation: paw-wave 3s infinite ease-in-out;
}

#volume-slider {
    width: 80px;
    -webkit-appearance: none;
    height: 6px;
    border-radius: 8px;
    background: linear-gradient(to right, #ffcccc, #ff6699);
    outline: none;
}

#volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #fff;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(255, 102, 153, 0.5);
    border: 2px solid #ff6699;
}

@keyframes paw-wave {
    0%, 100% { transform: rotate(0deg); }
    25% { transform: rotate(5deg); }
    75% { transform: rotate(-5deg); }
}

/* Xシェアボタン */
#share-section {
    display: flex;
    align-items: center;
    margin-left: 8px;
}

#x-share-btn {
    background: rgba(0, 0, 0, 0.8);
    color: white;
    border: none;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
    white-space: nowrap;
}

#x-share-btn:hover {
    background: rgba(0, 0, 0, 1);
    transform: scale(1.05);
}

/* スクロール可能なコンテンツエリア */
.scrollable-content {
    width: 90%;
    max-width: 1200px;
    margin: 30px auto;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23f0f0f0' fill-opacity='0.4'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    padding: 10px;
    border-radius: 15px;
}

#categories-container {
    width: 100%;
}
.youtubelink {
	font-size: 0.8em; /* フォントサイズを設定 */
	vertical-align: text-bottom;
	display: inline-block;
}
/* カテゴリーセクション */
.category-section {
    background-color: #ffffff;
    border-radius: 15px;
    padding: 10px;
    margin-bottom: 15px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    position: relative;
    overflow: visible;
    border: 1px solid #f0f0f0;
}

.category-section:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(74, 144, 226, 0.15);
}

.category-section h2 {
    margin: 2px 0 10px 0;
    padding-bottom: 5px;
    font-size: 1.4em;
}

.category-section h2 i {
    margin-left: 10px;
    color: #4a90e2;
    transition: transform 0.3s ease, color 0.3s ease;
}

.category-section h2:hover i {
    transform: rotate(15deg) scale(1.2);
    color: #ff9999;
}

.category-section::before {
    content: "✿";
    position: absolute;
    top: -10px;
    right: -5px;
    color: rgba(255, 153, 153, 0.6);
    font-size: 24px;
    transform: rotate(15deg);
}

.category-section::after {
    content: "✿";
    position: absolute;
    bottom: -12px;
    left: 20px;
    color: rgba(74, 144, 226, 0.4);
    font-size: 20px;
    transform: rotate(-10deg);
}

/* ボタンコンテナ */
.buttons-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 5px;
    justify-content: flex-start;
}

/* ボタン */
.play-button {
    background: linear-gradient(145deg, #ffffff, #f9f9f9);
    color: #664400;
    border: 1px solid #ffcccc;
    border-radius: 15px;
    padding: 6px 12px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.25s ease;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.05);
}

.play-button:hover {
    background: linear-gradient(145deg, #ffeeee, #fff9f9);
    border-color: #ff9999;
    color: #ff6666;
    transform: translateY(-3px);
    box-shadow: 0 5px 12px rgba(255, 102, 102, 0.2);
}

.play-button:active {
    transform: translateY(1px);
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.1);
}

/* キャプション */
.caption {
    font-size: 0.8em;
}

/* フッター */
footer {
    text-align: center;
    margin-top: 40px;
    padding: 20px 0;
    background-color: #fff;
    border-radius: 15px 15px 0 0;
    box-shadow: 0 -3px 10px rgba(0, 0, 0, 0.05);
    position: relative;
}

footer::before {
    content: "🍵";
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 20px;
    color: #ff9999;
}

footer a {
    position: relative;
    padding-bottom: 3px;
}

footer a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(to right, #4a90e2, #ff9999);
    transition: width 0.3s ease;
}

footer a:hover::after {
    width: 100%;
}

/* お問合せフォームモーダル */
.modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(3px);
}

.modal-content {
    background-color: #fff;
    margin: 5% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from { opacity: 0; transform: translateY(-50px) scale(0.9); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 12px 12px 0 0;
}

.modal-header h2 {
    margin: 0;
    font-size: 1.4em;
}

.close {
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
    transition: color 0.2s;
}

.close:hover {
    color: #ffeb3b;
}

#contactForm {
    padding: 25px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
    font-size: 0.95em;
}

.required {
    color: #e74c3c;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s, box-shadow 0.3s;
    font-family: inherit;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-actions {
    display: flex;
    gap: 12px;
    justify-content: flex-end;
    margin-top: 25px;
}

.btn-cancel,
.btn-submit {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    min-width: 100px;
}

.btn-cancel {
    background-color: #95a5a6;
    color: white;
}

.btn-cancel:hover {
    background-color: #7f8c8d;
    transform: translateY(-1px);
}

.btn-submit {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.btn-submit:hover {
    background: linear-gradient(135deg, #5a67d8 0%, #6b46c1 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.3);
}

/* =================================================================
   かしわねこボタン用レスポンシブデザイン - 統合・最適化版
   ================================================================= */

/* =================================================================
   高解像度画面対応（1200px以上）
   ================================================================= */
@media (min-width: 1200px) {
    .scrollable-content {
        max-width: 1400px;
    }

    .category-section h2 {
        font-size: 1.5em;
        padding: 12px 18px;
    }
}

/* =================================================================
   タブレットサイズ（768px以下）
   ================================================================= */
@media (max-width: 768px) {
    /* スティッキーヘッダー */
    .sticky-header {
        padding-bottom: 8px;
    }

    .sticky-header-inner {
        padding: 0 15px;
    }

    /* タイトル */
    h1 {
        font-size: 1.5em;
        margin: 15px auto 18px;
        padding: 6px 12px;
    }

    /* 注意書きボックス - タブレット用 */
    .box18 {
        font-size: 0.75em;
        margin: 1.5em auto;
        padding: 0.4em;
    }

    .box18 p {
        line-height: 1.4;
    }

    /* プレーヤー - タブレット用レイアウト */
    #player-container {
        flex-direction: column;
        padding: 10px;
        margin-bottom: 10px;
    }

    #player-controls {
        margin: 0 0 8px 0;
        justify-content: center;
    }

    #now-playing {
        margin: 5px 0;
        max-width: 100%;
        text-align: center;
    }

    #time-display {
        margin: 5px 0;
        text-align: center;
    }

    #volume-control {
        margin-top: 8px;
        width: 100%;
        justify-content: center;
    }

    #share-section {
        margin-top: 8px;
    }

    /* スクロール可能なコンテンツ */
    .scrollable-content {
        width: 95%;
        padding: 15px;
        margin: 20px auto;
    }

    /* カテゴリセクション */
    .category-section {
        padding: 12px 10px;
        margin-bottom: 12px;
    }

    .category-section h2 {
        font-size: 1.3em;
        margin-bottom: 10px;
    }

    /* ボタン */
    .play-button {
        padding: 6px 12px;
        font-size: 13px;
        margin: 3px;
    }

    /* フッター */
    footer {
        margin-top: 30px;
        padding: 15px 0;
    }
}

/* =================================================================
   スマホサイズ（480px以下）- かしわねこボタン用・4行表示・プレーヤーミニマム版
   ================================================================= */
@media (max-width: 480px) {
    /* スティッキーヘッダー全体を縮小 */
    .sticky-header {
        padding-bottom: 5px;
    }

    .sticky-header-inner {
        padding: 0 10px;
    }

    /* h1タイトルをコンパクトに - かしわねこ仕様 */
    h1 {
        font-size: 1.3em;
        margin: 10px auto 12px;
        padding: 6px 15px 8px;
        border-width: 1px; /* ボーダーを細く */
    }

    /* 装飾アニメーションを軽量化 */
    #emoji {
        animation: none; /* ホバーアニメーションを無効化 */
    }

    /* 注意書きボックス - 4行表示版（かしわねこ仕様） */
    .box18 {
        font-size: 0.65em;
        padding: 0.25em 0.6em;        /* 4行分のパディング */
        margin: 0.4em auto 0.9em;     /* 4行分のマージン */
        max-width: 95%;
    }

    .box18 p {
        font-size: 0.74em;            /* 4行に適したフォントサイズ */
        line-height: 1.15;            /* 4行に適した行間 */
        margin: 0;
        /* 4行表示に設定 */
        display: -webkit-box;
        -webkit-line-clamp: 4;        /* 4行表示 */
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    /* 改行を隠してテキストをコンパクト化 */
    .box18 br {
        display: none;
    }

    /* 装飾花を小さく */
    .box18:after {
        font-size: 20px; /* 28px → 20px */
        top: -8px;
    }

    .box18:before {
        font-size: 16px; /* 22px → 16px */
        bottom: -3px;
    }

    .flower1, .flower2 {
        font-size: 14px; /* 装飾花を小さく */
    }

    /* プレーヤーをミニマム表示に変更 - かしわねこ仕様 */
    #player-container {
        padding: 5px 10px;
        margin-bottom: 5px;
        border-radius: 12px;           /* 20px → 12px */
        height: 45px;                  /* 固定の低い高さ */
        display: flex;
        flex-direction: row;           /* 横並びに戻す */
        align-items: center;
        justify-content: space-between;
        overflow: hidden;
        border-width: 1px;             /* ボーダーを細く */
    }

    /* 装飾用の猫アイコンを小さく */
    .paw1, .paw2 {
        font-size: 12px; /* 20px,16px → 12px */
    }

    /* プレーヤーコントロール - 左側に配置 */
    #player-controls {
        display: flex;
        align-items: center;
        margin: 0;
        flex-shrink: 0;
    }

    #player-controls button {
        width: 32px;                   /* 36px → 32px */
        height: 32px;
        font-size: 14px;              /* 18px → 14px */
        margin-right: 5px;             /* 8px → 5px */
        padding: 0;
    }

    /* 再生ボタンの装飾を隠す */
    #play-pause-btn:after {
        display: none;
    }

    /* 現在再生中 - 中央に配置（縮小版） */
    #now-playing {
        flex: 1;
        font-size: 11px;              /* 14px → 11px */
        margin: 0 8px;                /* 10px → 8px */
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 120px;             /* 200px → 120px */
        text-align: left;
    }

    #current-audio-name {
        font-size: 11px;
        font-weight: 500;
    }

    /* 時間表示を隠す */
    #time-display {
        display: none;
    }

    /* 音量調整を最小化 - 右側に配置 */
    #volume-control {
        display: flex;
        align-items: center;
        margin: 0;
        flex-shrink: 0;
        width: auto;
        justify-content: flex-end;
    }

    #volume-control i {
        font-size: 10px;              /* 14px → 10px */
        margin: 0 3px;                /* 5px → 3px */
        animation: none;               /* アニメーションを無効化 */
    }

    #volume-slider {
        width: 40px;                  /* 80px → 40px */
        height: 3px;                  /* 6px → 3px */
    }

    #volume-slider::-webkit-slider-thumb {
        width: 12px;                  /* 16px → 12px */
        height: 12px;
    }

    /* Xシェアボタンを小さく */
    #share-section {
        margin-left: 5px;            /* 8px → 5px */
        margin-top: 0;
    }

    #x-share-btn {
        padding: 3px 6px;            /* 4px 8px → 3px 6px */
        font-size: 9px;              /* 11px → 9px */
        border-radius: 8px;          /* 12px → 8px */
    }

    #x-share-btn span {
        font-size: 9px;
    }

    /* スクロール可能なコンテンツの調整 */
    .scrollable-content {
        width: 95%;
        margin: 15px auto;           /* 30px → 15px */
        padding: 12px;               /* 10px → 12px */
    }

    /* カテゴリーセクション */
    .category-section {
        padding: 8px 10px;           /* 10px → 8px */
        margin-bottom: 12px;         /* 15px → 12px */
        border-radius: 12px;         /* 15px → 12px */
    }

    .category-section h2 {
        font-size: 1.2em;           /* 1.4em → 1.2em */
        margin: 2px 0 8px 0;        /* 10px → 8px */
        padding-bottom: 3px;        /* 5px → 3px */
    }

    /* 装飾花を小さく */
    .category-section::before {
        font-size: 18px;            /* 24px → 18px */
        top: -8px;
    }

    .category-section::after {
        font-size: 16px;            /* 20px → 16px */
        bottom: -10px;
    }

    /* 音声ボタンを小さく */
    .play-button {
        font-size: 12px;            /* 14px → 12px */
        padding: 6px 10px;          /* 6px 12px → 6px 10px */
        margin: 2px;                /* 8px → 2px */
        border-radius: 12px;        /* 15px → 12px */
    }

    /* ボタンコンテナ */
    .buttons-container {
        gap: 5px;                   /* 8px → 5px */
        padding: 3px;               /* 5px → 3px */
    }

    /* キャプション */
    .caption {
        font-size: 0.7em;          /* 0.8em → 0.7em */
    }

    /* フッター調整 */
    footer {
        margin-top: 20px;           /* 40px → 20px */
        padding: 15px 0;            /* 20px → 15px */
        border-radius: 12px 12px 0 0; /* 15px → 12px */
    }

    footer::before {
        font-size: 16px;            /* 20px → 16px */
        top: -12px;
    }

    footer a {
        font-size: 0.8em;
        margin: 3px 5px;
        padding: 6px 8px;
    }
}

/* =================================================================
   非常に小さい画面（360px以下）での最終調整 - かしわねこ仕様
   ================================================================= */
@media (max-width: 360px) {
    /* タイトルをさらに小さく */
    h1 {
        font-size: 1.15em;
        margin: 8px auto 10px;
        padding: 5px 12px 6px;
    }

    /* 注意書き - 360px以下でも4行表示を維持 */
    .box18 {
        font-size: 0.6em;           /* さらに小さく */
        margin: 0.3em auto 0.7em;
        padding: 0.2em 0.5em;
    }

    .box18 p {
        font-size: 0.7em;           /* 360px用のフォントサイズ */
        line-height: 1.1;           /* 行間をタイト目に */
        -webkit-line-clamp: 4;      /* 4行表示を維持 */
    }

    /* 装飾をさらに小さく */
    .box18:after {
        font-size: 16px;
        top: -6px;
    }

    .box18:before {
        font-size: 14px;
        bottom: -2px;
    }

    /* プレーヤーをさらに小さく */
    #player-container {
        height: 40px;
        padding: 4px 8px;
        border-radius: 10px;
    }

    #player-controls button {
        width: 28px;
        height: 28px;
        font-size: 12px;
        margin-right: 4px;
    }

    #now-playing {
        font-size: 10px;
        max-width: 100px;
        margin: 0 6px;
    }

    #current-audio-name {
        font-size: 10px;
    }

    #volume-control i {
        font-size: 9px;
        margin: 0 2px;
    }

    #volume-slider {
        width: 35px;
        height: 2px;
    }

    #volume-slider::-webkit-slider-thumb {
        width: 10px;
        height: 10px;
    }

    /* ボタンをさらに小さく */
    .play-button {
        font-size: 11px;
        padding: 5px 8px;
        margin: 1px;
        border-radius: 10px;
    }

    /* コンテンツのパディング削減 */
    .scrollable-content {
        padding: 10px;
        margin: 10px auto;
    }

    /* カテゴリタイトル調整 */
    .category-section {
        padding: 6px 8px;
        margin-bottom: 10px;
    }

    .category-section h2 {
        font-size: 1.1em;
        margin: 2px 0 6px 0;
    }

    /* フッター */
    footer {
        padding: 12px 0;
    }

    footer a {
        font-size: 0.75em;
        margin: 2px 3px;
        padding: 5px 6px;
    }
}

/* =================================================================
   横向きスマホでの調整（768px以下 かつ 横向き）- かしわねこ仕様
   ================================================================= */
@media (max-width: 768px) and (orientation: landscape) {
    /* タイトル */
    h1 {
        font-size: 1.3em;
        margin: 6px auto 10px;
    }

    /* 注意書き - 横向きでは3行に制限 */
    .box18 {
        margin: 0.3em auto 0.7em;
        font-size: 0.7em;
    }

    .box18 p {
        -webkit-line-clamp: 3;      /* 横向きでは3行に制限 */
        line-height: 1.15;
    }

    /* 横向きでもプレーヤーはミニマム表示を維持 */
    #player-container {
        height: 42px;
        padding: 5px 12px;
        max-width: 600px;
        flex-direction: row;
        margin-bottom: 8px;
    }

    #player-controls {
        margin-right: 10px;
        margin-bottom: 0;
    }

    #now-playing {
        max-width: 180px;
        margin: 0 10px;
        text-align: left;
    }

    #volume-control {
        margin: 0;
        width: auto;
        justify-content: flex-end;
    }

    #volume-slider {
        width: 50px;
    }

    #share-section {
        margin-top: 0;
        margin-left: 8px;
    }

    /* 時間表示は横向きでも隠す */
    #time-display {
        display: none;
    }

    /* スクロール可能なコンテンツ */
    .scrollable-content {
        margin: 12px auto;
    }
}

/* =================================================================
   メモリ効率化とパフォーマンス最適化 - かしわねこ仕様
   ================================================================= */
@media (max-width: 768px) {
    /* GPU加速の制限（必要な要素のみに適用） */
    .memory-optimized,
    .play-button,
    #player-controls button,
    .sticky-header {
        will-change: auto;
        backface-visibility: hidden;
        transform: translateZ(0);
    }

    /* アニメーションの簡素化 */
    .play-button {
        transition: transform 0.2s ease;
    }

    .play-button:hover {
        transform: translateY(-2px);
    }

    /* 装飾アニメーションを軽量化 */
    body:before, body:after {
        animation-duration: 20s; /* より長い周期に */
    }

    .sticky-header::before {
        animation-duration: 12s; /* より長い周期に */
    }

    /* 不要なアニメーションを無効化 */
    @media (prefers-reduced-motion: reduce) {
        *,
        *::before,
        *::after {
            animation-duration: 0.01ms !important;
            animation-iteration-count: 1 !important;
            transition-duration: 0.01ms !important;
        }
    }
}

/* メモリ効率化 */
audio { display: block; max-width: 100%; }
.memory-optimized { will-change: auto; backface-visibility: hidden; }