/**
 * 낚시의 달인 - Game Specific Styles
 * Inherits from ../css/common.css
 */
/* ===== Fishing-specific CSS Variables ===== */
:root {
    --water-color: #1a5f7a;
    --water-dark: #0d3d4d;
    --sky-gradient: linear-gradient(180deg, #87CEEB 0%, #4A90A4 50%, #1a5f7a 100%);
}

/* ===== Location Info in Game Header ===== */
.location-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
}
#location-name {
    font-weight: 600;
    font-size: 0.95rem;
}
#weather-info {
    font-size: 0.8rem;
    color: var(--text-secondary);
}
/* ===== Bait Indicator ===== */
.bait-indicator {
    font-size: 1.2rem;
}
.bait-count {
    font-size: 0.85rem;
    color: var(--text-secondary);
}
/* ===== Gold Card ===== */
.gold-card .gold-indicator {
    font-size: 1.2rem;
}
.catch-count {
    font-size: 0.85rem;
    color: var(--text-secondary);
}
/* ===== Control Panel (Power, Tension, HP Gauges) ===== */
.control-panel {
    position: absolute;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    width: 90%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    z-index: 20;
    pointer-events: none;
}
.gauge-wrapper {
    background: rgba(0, 0, 0, 0.7);
    border-radius: var(--radius-md);
    padding: 10px 15px;
    backdrop-filter: blur(10px);
    pointer-events: auto;
}
.gauge-label {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 6px;
}
/* ===== Power Bar ===== */
.power-bar {
    height: 16px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}
.power-fill {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg,
        var(--success) 0%,
        var(--warning) 50%,
        var(--danger) 100%);
    border-radius: 8px;
    transition: width 0.05s linear;
}
.power-value {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 4px;
    display: block;
    text-align: right;
}
/* ===== Tension Bar ===== */
.tension-bar {
    height: 20px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}
.tension-zones {
    display: flex;
    height: 100%;
    position: relative;
}
.tension-zones .zone {
    height: 100%;
}
.zone-danger-low {
    width: 20%;
    background: var(--danger);
    opacity: 0.5;
}
.zone-warning-low {
    width: 15%;
    background: var(--warning);
    opacity: 0.5;
}
.zone-optimal {
    width: 30%;
    background: var(--success);
    opacity: 0.6;
}
.zone-warning-high {
    width: 20%;
    background: var(--warning);
    opacity: 0.5;
}
.zone-danger-high {
    width: 15%;
    background: var(--danger);
    opacity: 0.5;
}
.tension-fill {
    position: absolute;
    left: 0;
    top: 0;
    height: 100%;
    width: 50%;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 10px;
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.5);
    transition: width 0.1s ease, background-color 0.2s ease;
}
.tension-value {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 4px;
    display: block;
    text-align: right;
}
/* ===== Fish HP Bar ===== */
.hp-bar {
    height: 16px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 8px;
    overflow: hidden;
}
.hp-fill {
    height: 100%;
    width: 100%;
    background: linear-gradient(90deg,
        var(--danger) 0%,
        var(--warning) 50%,
        var(--success) 100%);
    background-size: 200% 100%;
    border-radius: 8px;
    transition: width 0.15s ease;
}
.hp-value {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-top: 4px;
    display: block;
    text-align: right;
}
/* ===== Fighting Controls ===== */
.fighting-controls {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 20px;
    z-index: 20;
}
.control-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    padding: 18px 30px;
    border: none;
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.15s ease;
    box-shadow: var(--shadow-md);
    touch-action: manipulation;
    -webkit-user-select: none;
    user-select: none;
}
.control-btn .btn-icon {
    font-size: 1.8rem;
}
.control-btn .btn-label {
    font-size: 0.85rem;
}
.btn-reel {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white;
}
.btn-reel:active {
    background: var(--primary-dark);
    transform: scale(0.95);
}
.btn-hold {
    background: linear-gradient(135deg, var(--warning), #e68a00);
    color: white;
}
.btn-hold:active {
    background: #e68a00;
    transform: scale(0.95);
}
/* ===== Game Status Indicator ===== */
.game-status-indicator {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    padding: 10px 20px;
    background: rgba(0, 0, 0, 0.75);
    border-radius: var(--radius-md);
    font-size: 1rem;
    font-weight: 500;
    color: white;
    text-align: center;
    z-index: 50;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}
.game-status-indicator.show {
    opacity: 1;
}
.game-status-indicator.bite {
    color: var(--warning);
    animation: shake 0.3s ease-in-out infinite;
}
@keyframes shake {
    0%, 100% { transform: translateX(-50%); }
    25% { transform: translateX(calc(-50% - 8px)); }
    75% { transform: translateX(calc(-50% + 8px)); }
}
/* ===== Result Modal - Fish Display ===== */
.result-fish-display {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    margin: 20px 0;
}
.result-fish-display .fish-emoji {
    font-size: 5rem;
    animation: fishSwim 2s ease-in-out infinite;
}
@keyframes fishSwim {
    0%, 100% { transform: translateX(0) scaleX(1); }
    25% { transform: translateX(10px) scaleX(1); }
    50% { transform: translateX(0) scaleX(-1); }
    75% { transform: translateX(-10px) scaleX(-1); }
}
.result-fish-display .fish-details {
    text-align: center;
}
.result-fish-display .fish-name {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--accent);
    margin-bottom: 5px;
}
.result-fish-display .fish-size {
    font-size: 1.1rem;
    color: var(--text-primary);
    margin-bottom: 3px;
}
.result-fish-display .fish-rarity {
    font-size: 0.95rem;
    color: var(--text-secondary);
}
/* Rarity Colors */
.fish-rarity.rare {
    color: #9b59b6;
}
.fish-rarity.epic {
    color: #e74c3c;
}
.fish-rarity.legendary {
    color: #f39c12;
    text-shadow: 0 0 10px rgba(243, 156, 18, 0.5);
}
.fish-rarity.mythic {
    color: #e91e63;
    text-shadow: 0 0 15px rgba(233, 30, 99, 0.6);
    animation: mythicGlow 1.5s ease-in-out infinite;
}
@keyframes mythicGlow {
    0%, 100% { text-shadow: 0 0 15px rgba(233, 30, 99, 0.6); }
    50% { text-shadow: 0 0 25px rgba(233, 30, 99, 0.9); }
}
/* ===== Result Fail State ===== */
.result-fish-display.fail {
    display: none;
}
#result-title.fail {
    color: var(--danger);
}
/* ===== Collection Modal ===== */
.collection-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
    padding: 10px 0;
}
.collection-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s ease;
}
.collection-item:hover {
    background: rgba(255, 255, 255, 0.1);
}
.collection-item.locked {
    opacity: 0.4;
    filter: grayscale(100%);
}
.collection-item .fish-icon {
    font-size: 2.5rem;
    margin-bottom: 5px;
}
.collection-item .fish-label {
    font-size: 0.75rem;
    color: var(--text-secondary);
    text-align: center;
}
/* ===== Equipment Modal ===== */
.equipment-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 400px;
    overflow-y: auto;
}
.equipment-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all 0.2s ease;
}
.equipment-item:hover {
    background: rgba(255, 255, 255, 0.1);
}
.equipment-item.equipped {
    border: 2px solid var(--primary);
}
.equipment-item .equip-icon {
    font-size: 2rem;
}
.equipment-item .equip-info {
    flex: 1;
}
.equipment-item .equip-name {
    font-weight: 600;
    margin-bottom: 3px;
}
.equipment-item .equip-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
}
/* ===== Tutorial Modal (Go-Stop Style) ===== */
.modal-tutorial {
    max-width: 820px;
    width: 95%;
    max-height: 90vh;
    overflow-y: auto;
}
.tutorial-wrapper {
    display: flex;
    gap: 25px;
    margin: 20px 0;
}
.tutorial-visual {
    flex: 0 0 380px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
#tutorial-canvas {
    background: linear-gradient(135deg, var(--water-color) 0%, var(--water-dark) 100%);
    border-radius: 12px;
    border: 2px solid rgba(26, 95, 122, 0.5);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}
.tutorial-caption {
    margin-top: 12px;
    font-size: 13px;
    color: var(--accent);
    text-align: center;
    min-height: 20px;
    line-height: 1.4;
}
.tutorial-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}
.tutorial-text h3 {
    margin: 0 0 12px 0;
    color: var(--accent);
    font-size: 20px;
}
.tutorial-text p {
    margin: 0;
    line-height: 1.7;
    color: var(--text-primary);
    font-size: 14px;
    white-space: pre-line;
}
.tutorial-navigation {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}
.tutorial-dots {
    display: flex;
    gap: 8px;
    justify-content: center;
    align-items: center;
}
.tutorial-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}
.tutorial-dot:hover {
    background: rgba(255, 255, 255, 0.5);
}
.tutorial-dot.active {
    background: var(--accent);
    transform: scale(1.2);
}
.tutorial-dot.completed {
    background: var(--success);
}
/* Responsive Tutorial */
@media (max-width: 700px) {
    .modal-tutorial {
        max-width: 95%;
        padding: 15px;
    }
    .tutorial-wrapper {
        flex-direction: column;
        gap: 15px;
    }
    .tutorial-visual {
        flex: none;
        width: 100%;
    }
    #tutorial-canvas {
        width: 100%;
        max-width: 340px;
        height: auto;
        aspect-ratio: 360 / 280;
    }
    .tutorial-text h3 {
        font-size: 17px;
    }
    .tutorial-text p {
        font-size: 13px;
    }
    .tutorial-dot {
        width: 8px;
        height: 8px;
    }
    .tutorial-navigation .btn {
        padding: 8px 16px;
        font-size: 13px;
    }
}
/* ===== Locked Fishing Spots ===== */
.room-item.locked {
    opacity: 0.6;
    cursor: not-allowed;
}
.room-item.locked:hover {
    transform: none;
    box-shadow: none;
}
/* ===== Game Area Override ===== */
.game-room .game-area {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
    width: 100%;
    height: 100%;
}

/* AI/멀티플레이 모드에서 table-container 크기 확장 */
.game-room .table-container {
    flex: 1;
    min-height: 400px;
    max-height: none;
    height: 100%;
}
/* ===== Table Container & Canvas ===== */
.table-container {
    position: relative;
    width: 100%;
    flex: 1;
    min-height: 300px;
    max-height: 80vh;
    overflow: hidden;
    background: #0a1628;
    border-radius: 8px;
}
/* Phaser가 생성하는 캔버스 - 반응형 확대/축소 */
.table-container canvas {
    display: block !important;
    width: 100%;
    height: 100%;
    border-radius: 8px;
    will-change: transform;
}
/* Phaser가 자체 캔버스를 생성하므로 #game-canvas 불필요 */
/* ===== Recent Catch List ===== */
#recent-catch .catch-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
#recent-catch .catch-item:last-child {
    border-bottom: none;
}
#recent-catch .catch-emoji {
    font-size: 1.5rem;
}
#recent-catch .catch-info {
    flex: 1;
}
#recent-catch .catch-name {
    font-weight: 600;
    font-size: 0.9rem;
}
#recent-catch .catch-size {
    font-size: 0.8rem;
    color: var(--text-secondary);
}
/* ===== Mobile Responsive ===== */
@media (max-width: 768px) {
    .table-container {
        flex: 1;
        min-height: 250px;
        max-height: 60vh;
    }
    .control-panel {
        bottom: 140px;
        width: 95%;
    }
    .fighting-controls {
        bottom: 80px;
    }
    .control-btn {
        padding: 15px 25px;
    }
    .control-btn .btn-icon {
        font-size: 1.5rem;
    }
    .location-info {
        position: static;
        transform: none;
    }
}
@media (max-width: 480px) {
    .control-btn {
        padding: 12px 20px;
    }
    .gauge-wrapper {
        padding: 8px 12px;
    }
    .power-bar,
    .tension-bar,
    .hp-bar {
        height: 14px;
    }
}
/* ===== Landscape Mode ===== */
@media (orientation: landscape) and (max-height: 500px) {
    .control-panel {
        bottom: 60px;
        flex-direction: row;
        max-width: 90%;
        gap: 15px;
    }
    .gauge-wrapper {
        flex: 1;
        padding: 6px 10px;
    }
    .fighting-controls {
        bottom: 10px;
    }
    .control-btn {
        padding: 10px 20px;
    }
    .control-btn .btn-icon {
        font-size: 1.3rem;
    }
    .control-btn .btn-label {
        font-size: 0.75rem;
    }
}
/* ===== Participant Badge ===== */
.participant-badge {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 4px;
  font-weight: 500;
}
.participant-badge.host {
  background: #f1c40f;
  color: #000;
}
/* ===== CHAT TABS & PARTICIPANT LIST ===== */
.chat-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 0;
}
.chat-tab {
  flex: 1;
  padding: 10px 15px;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.chat-tab:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}
.chat-tab.active {
  color: var(--accent);
  border-bottom: 2px solid var(--accent);
  font-weight: 500;
}
.participant-count {
  background: var(--accent);
  color: white;
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
}
.tab-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
#chat-content {
  display: flex;
  flex-direction: column;
  height: 100%;
}
#chat-content .chat-messages {
  flex: 1;
}
/* Participants List */
.participants-list {
  padding: 10px;
  overflow-y: auto;
  height: 100%;
}
.participant-section {
  margin-bottom: 15px;
}
.participant-section-header {
  font-size: 12px;
  color: var(--text-secondary);
  font-weight: 600;
  margin-bottom: 8px;
  padding-bottom: 5px;
  border-bottom: 1px solid var(--border-color);
}
.participant-items {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.participant-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  background: var(--bg-secondary);
  border-radius: 8px;
  font-size: 13px;
}
.participant-item.player {
  border-left: 3px solid var(--accent);
}
.participant-item.host {
  border-left: 3px solid #f1c40f;
}
.participant-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--bg-hover);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}
.participant-info {
  flex: 1;
}
.participant-name {
  font-weight: 500;
  color: var(--text-primary);
}
.participant-role {
  font-size: 11px;
  color: var(--text-secondary);
}
.empty-participants {
  text-align: center;
  color: var(--text-secondary);
  padding: 20px;
  font-size: 13px;
}
/* ===== SHOP (FULL SCREEN) ===== */
.shop-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
  z-index: 2000;
  display: none;
  flex-direction: column;
  overflow: hidden;
}
.shop-overlay.active {
  display: flex;
}
/* Shop Header */
.shop-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 20px;
  background: rgba(0, 0, 0, 0.4);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}
.shop-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.3rem;
  font-weight: 700;
  color: #ffd700;
}
.shop-icon {
  font-size: 1.5rem;
}
.shop-info-btn {
  background: none;
  border: none;
  font-size: 1rem;
  cursor: pointer;
  opacity: 0.7;
  transition: opacity 0.2s;
}
.shop-info-btn:hover {
  opacity: 1;
}
.shop-currency {
  display: flex;
  gap: 15px;
}
.currency-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 20px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}
.currency-item.gold {
  border-color: rgba(255, 215, 0, 0.3);
}
.currency-item.diamond {
  border-color: rgba(0, 191, 255, 0.3);
}
.currency-icon {
  font-size: 1.1rem;
}
.currency-value {
  font-weight: 600;
  font-size: 0.95rem;
  color: #fff;
  min-width: 50px;
}
.currency-add {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #4ade80, #22c55e);
  border: none;
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s;
}
.currency-add:hover {
  transform: scale(1.1);
}
.shop-close-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: none;
  color: #fff;
  font-size: 1.2rem;
  cursor: pointer;
  transition: all 0.2s;
}
.shop-close-btn:hover {
  background: rgba(255, 100, 100, 0.3);
}
/* Shop Content */
.shop-content {
  flex: 1;
  display: flex;
  overflow: hidden;
}
/* Shop Sidebar */
.shop-sidebar {
  width: 140px;
  background: rgba(0, 0, 0, 0.3);
  border-right: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  flex-direction: column;
  padding: 10px 0;
}
.shop-category {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  padding: 15px 10px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  cursor: pointer;
  transition: all 0.2s;
  border-left: 3px solid transparent;
}
.shop-category:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}
.shop-category.active {
  background: rgba(255, 215, 0, 0.1);
  color: #ffd700;
  border-left-color: #ffd700;
}
.category-icon {
  font-size: 1.5rem;
}
.category-name {
  font-size: 0.8rem;
  font-weight: 500;
}
/* Shop Main Area */
.shop-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 15px;
  max-width: 500px;
}
/* Shop Tabs */
.shop-tabs {
  display: flex;
  gap: 5px;
  margin-bottom: 15px;
  background: rgba(0, 0, 0, 0.2);
  padding: 5px;
  border-radius: 8px;
}
.shop-tab {
  flex: 1;
  padding: 10px 15px;
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s;
}
.shop-tab:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}
.shop-tab.active {
  background: linear-gradient(135deg, #e94560, #c73e54);
  color: #fff;
}
/* Shop Preview */
.shop-preview {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 12px;
  padding: 20px;
  position: relative;
  overflow: hidden;
}
.shop-preview::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(ellipse at center, rgba(255, 215, 0, 0.1) 0%, transparent 70%);
  pointer-events: none;
}
.preview-image {
  width: 200px;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 15px;
}
.preview-image img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.5));
}
.preview-info {
  text-align: center;
  margin-bottom: 15px;
}
.preview-name {
  font-size: 1.2rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 8px;
}
.preview-stats {
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.7);
  line-height: 1.5;
}
.preview-price {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 25px;
  background: linear-gradient(135deg, #ffd700, #ffb700);
  border-radius: 25px;
  margin-bottom: 15px;
  box-shadow: 0 4px 15px rgba(255, 215, 0, 0.3);
}
.price-icon {
  font-size: 1.2rem;
}
.price-value {
  font-size: 1.3rem;
  font-weight: 700;
  color: #1a1a2e;
}
.shop-buy-btn {
  width: 100%;
  max-width: 200px;
  padding: 12px 30px;
  font-size: 1rem;
  font-weight: 600;
}
.shop-buy-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
/* Shop Items */
.shop-items {
  width: 280px;
  background: rgba(0, 0, 0, 0.2);
  border-left: 1px solid rgba(255, 255, 255, 0.1);
  padding: 15px;
  overflow-y: auto;
}
.shop-item-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.shop-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.2s;
  border: 2px solid transparent;
  position: relative;
}
.shop-item:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
}
.shop-item.selected {
  background: rgba(233, 69, 96, 0.2);
  border-color: #e94560;
}
.shop-item.owned {
  opacity: 0.6;
}
.shop-item.owned::after {
  content: '보유중';
  position: absolute;
  top: 5px;
  right: 5px;
  font-size: 0.7rem;
  padding: 2px 6px;
  background: #4ade80;
  color: #000;
  border-radius: 4px;
  font-weight: 600;
}
.item-image {
  width: 60px;
  height: 60px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
.item-image img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}
.item-info {
  flex: 1;
}
.item-name {
  font-weight: 600;
  color: #fff;
  margin-bottom: 4px;
  font-size: 0.9rem;
}
.item-grade {
  font-size: 0.75rem;
  padding: 2px 6px;
  border-radius: 4px;
  display: inline-block;
  margin-bottom: 4px;
}
.item-grade.common { background: #6b7280; color: #fff; }
.item-grade.uncommon { background: #22c55e; color: #fff; }
.item-grade.rare { background: #3b82f6; color: #fff; }
.item-grade.epic { background: #a855f7; color: #fff; }
.item-grade.legendary { background: linear-gradient(135deg, #fbbf24, #f59e0b); color: #000; }
.item-price {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 0.85rem;
  color: #ffd700;
}
/* Sale Badge */
.sale-badge {
  position: absolute;
  top: -5px;
  left: -5px;
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 4px;
  transform: rotate(-15deg);
}
/* Mobile Responsive */
@media (max-width: 820px) {
  .shop-content {
    flex-direction: column;
  }
  .shop-sidebar {
    width: 100%;
    flex-direction: row;
    overflow-x: auto;
    padding: 5px 10px;
    border-right: none;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  }
  .shop-category {
    flex-direction: row;
    padding: 10px 15px;
    border-left: none;
    border-bottom: 2px solid transparent;
    white-space: nowrap;
  }
  .shop-category.active {
    border-left-color: transparent;
    border-bottom-color: #ffd700;
  }
  .category-icon {
    font-size: 1.2rem;
  }
  .shop-main {
    max-width: none;
    padding: 10px;
  }
  .shop-items {
    width: 100%;
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    max-height: 250px;
  }
  .shop-item-grid {
    flex-direction: row;
    flex-wrap: wrap;
  }
  .shop-item {
    width: calc(50% - 5px);
    flex-direction: column;
    text-align: center;
  }
  .preview-image {
    width: 150px;
    height: 150px;
  }
  .shop-currency {
    gap: 8px;
  }
  .currency-item {
    padding: 4px 8px;
  }
  .currency-value {
    min-width: 40px;
    font-size: 0.85rem;
  }
}
@media (max-width: 480px) {
  .shop-header {
    padding: 8px 12px;
  }
  .shop-title {
    font-size: 1.1rem;
  }
  .shop-item {
    width: 100%;
    flex-direction: row;
    text-align: left;
  }
  .preview-image {
    width: 120px;
    height: 120px;
  }
}

/* Responsive Ads */
@media (max-width: 768px) {
  .ad-pc-only { display: none !important; }
}
@media (min-width: 769px) {
  .ad-mobile-only { display: none !important; }
}

/* Ad Lobby Center */
.ad-lobby {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
}

/* 게임방 모바일 하단 광고 320x50 (스크롤) */
.ad-mobile-fixed {
  position: static;
  margin: 10px auto;
  width: 320px;
  height: 50px;
}

.ad-mobile-fixed.hidden {
  display: none;
}

/* ============================================
   GUIDE SLIDE PANEL (SEO 가이드)
   ============================================ */

/* Overlay */
.guide-slide-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 9998;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.guide-slide-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* Slide Panel */
.guide-slide-panel {
  display: none;
  position: fixed;
  top: 0;
  right: -450px;
  width: 450px;
  max-width: 90vw;
  height: 100%;
  background: var(--bg-secondary);
  z-index: 9999;
  transition: right 0.3s ease;
  flex-direction: column;
  box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
}

.guide-slide-panel.active {
  display: flex;
  right: 0;
}

/* Header */
.guide-slide-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 20px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.guide-slide-header h2 {
  margin: 0;
  font-size: 18px;
  color: var(--text-primary);
}

.guide-slide-close {
  background: none;
  border: none;
  font-size: 28px;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: color 0.2s;
}

.guide-slide-close:hover {
  color: var(--accent);
}

/* Content */
.guide-slide-content {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
}

.guide-article {
  color: var(--text-primary);
}

/* Sections */
.guide-section {
  margin-bottom: 24px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border);
}

.guide-section:last-child {
  border-bottom: none;
  margin-bottom: 0;
}

.guide-section h3 {
  font-size: 16px;
  color: var(--accent);
  margin: 0 0 12px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}

.guide-section p {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin: 0;
}

/* Definition Lists */
.guide-definition-list {
  margin: 0;
}

.guide-definition-list dt {
  font-weight: bold;
  color: var(--text-primary);
  font-size: 14px;
  margin-top: 10px;
}

.guide-definition-list dt:first-child {
  margin-top: 0;
}

.guide-definition-list dd {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Tips List */
.guide-tips-list {
  margin: 0;
  padding-left: 20px;
}

.guide-tips-list li {
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 8px;
}

.guide-tips-list li:last-child {
  margin-bottom: 0;
}

/* FAQ List */
.guide-faq-list {
  margin: 0;
}

.guide-faq-list dt {
  font-weight: bold;
  color: var(--text-primary);
  font-size: 14px;
  margin-top: 12px;
}

.guide-faq-list dt:first-child {
  margin-top: 0;
}

.guide-faq-list dd {
  margin: 6px 0 0 0;
  font-size: 13px;
  color: var(--text-secondary);
  line-height: 1.5;
  padding-left: 12px;
  border-left: 2px solid var(--accent);
}

/* Mobile Responsive */
@media (max-width: 480px) {
  .guide-slide-panel {
    width: 100%;
    max-width: 100%;
    right: -100%;
  }

  .guide-slide-panel.active {
    display: flex;
    right: 0;
  }

  .guide-slide-header {
    padding: 14px 16px;
  }

  .guide-slide-header h2 {
    font-size: 16px;
  }

  .guide-slide-content {
    padding: 16px;
  }

  .guide-section h3 {
    font-size: 15px;
  }
}

/* ============================================
   SIDEBAR TABS (정보/채팅 탭)
   ============================================ */
.sidebar {
  padding: 1px;
  gap: 1px;
}

.sidebar-tabs {
  display: flex;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 1px;
  flex-shrink: 0;
}

.sidebar-tab {
  flex: 1;
  padding: 10px;
  background: transparent;
  border: none;
  color: var(--text-secondary);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.sidebar-tab:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.sidebar-tab.active {
  color: var(--accent);
  border-bottom: 2px solid var(--accent);
  margin-bottom: -1px;
}

.sidebar-tab-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 1px;
  overflow-y: auto;
  min-height: 0;
}

/* 채팅 탭 콘텐츠 - chat-panel 스타일 */
#sidebar-chat-content .chat-panel {
  display: flex;
  flex-direction: column;
  flex: 1;
  background: var(--bg-card);
  border-radius: 1px;
  overflow: hidden;
  min-height: 0;
}

#sidebar-chat-content .chat-section {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: 0;
}

#sidebar-chat-content .chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1px;
  min-height: 150px;
}

#sidebar-chat-content .game-controls {
  padding: 10px;
  border-top: 1px solid var(--border-color);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex-shrink: 0;
}

#sidebar-chat-content .game-controls .btn {
  flex: 1;
  min-width: 80px;
}

/* 광고 컨테이너 */
.sidebar .ad-sidebar {
  flex-shrink: 0;
  margin-top: auto;
  display: flex;
  justify-content: center;
}


/* 820px 이하 (모바일)에서 sidebar 숨김 */
@media (max-width: 820px) {
  .sidebar-tabs {
    display: none;
  }
}

/* ============================================
   MOBILE JOYSTICK CONTROLS
   ============================================ */
.mobile-controls {
  display: none;
  position: absolute;
  bottom: 3px;
  right: 3px;
  z-index: 100;
  opacity: 0.7;
  transition: opacity 0.2s;
}

.mobile-controls:active {
  opacity: 0.95;
}

.joystick-container {
  position: relative;
  width: 120px;
  height: 120px;
  display: flex;
  justify-content: center;
  align-items: center;
}

.joystick-base {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  background: rgba(30, 30, 30, 0.7);
  border: 3px solid rgba(255, 255, 255, 0.3);
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  touch-action: none;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
}

.joystick-knob {
  width: 45px;
  height: 45px;
  border-radius: 50%;
  background: var(--accent, #1a5f7a);
  position: absolute;
  pointer-events: none;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
}

/* Show mobile controls only on mobile (768px and below) */
@media (max-width: 768px) {
  .game-room .mobile-controls {
    display: flex;
  }
}
