/* Boss计时器样式 */

/* 卡片基础样式 */
.boss-card {
    transition: transform 0.2s, box-shadow 0.2s;
}

.boss-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

/* 简约模式 - 只显示Boss名称和计时器 */
#boss-page-container.simple-mode .boss-details,
.simple-mode .boss-details {
    display: none !important;
}

/* 确保图片模式和文字模式在所有设备上都显示boss-details */
#boss-page-container.image-mode .boss-details,
#boss-page-container.text-mode .boss-details,
.image-mode .boss-details,
.text-mode .boss-details {
    display: block !important;
}

.simple-mode .boss-card {
    padding: 8px;
}

.simple-mode .boss-name {
    font-size: 0.875rem;
    font-weight: 600;
    margin-top: 0.5rem;
}

/* 文字模式 - 隐藏图片区域后的布局调整 */
.text-mode .boss-card {
    min-height: auto;
}

.text-mode .boss-card .h-32 {
    display: none;
}

.text-mode .boss-name {
    margin-top: 0;
    font-size: 1.125rem;
    font-weight: 600;
}

.text-mode .boss-details {
    margin-top: 0.5rem;
}

/* 图片样式 */
.boss-card img {
    object-fit: contain;
    width: 100%;
    height: 100%;
    border-radius: 8px;
}

/* 图片容器样式 */
.boss-card .h-32 {
    height: 5rem !important; /* 确保高度生效 */
}

/* 修复Tailwind高度类被覆盖的问题 */
.h-32 {
    height: 5rem !important;
}

/* 按钮组样式 */
.inline-flex button {
    transition: all 0.2s ease-in-out;
}

.inline-flex button:focus {
    outline: none;
    ring: 2px;
    ring-color: rgb(59, 130, 246);
}

/* 隐藏区域 */
#hidden-bosses-content {
    transition: all 0.3s ease-in-out;
}

#hidden-bosses-toggle {
    cursor: pointer;
    user-select: none;
}

#hidden-bosses-toggle:hover {
    color: #1f2937;
}

#hidden-bosses-toggle svg {
    transition: transform 0.3s ease-in-out;
    display: inline-block;
}

/* 输入框 */
.refresh-duration:focus {
    border-color: rgb(59, 130, 246);
    ring: 2px;
    ring-color: rgba(59, 130, 246, 0.2);
}

/* 激活状态 */
.tag-btn.bg-blue-600,
.mode-btn.bg-blue-600 {
    box-shadow: inset 0 2px 4px 0 rgba(0, 0, 0, 0.06);
}

/* 加载状态 */
.boss-card.loading {
    opacity: 0.6;
    pointer-events: none;
}

/* 错误状态 */
.boss-card.error {
    border-color: rgb(239, 68, 68);
    background-color: rgba(254, 242, 242, 0.5);
}

/* 移动端响应式 */
@media (max-width: 768px) {
    .flex.flex-col.sm\:flex-row {
        flex-direction: column !important;
        align-items: flex-start !important;
    }

    .inline-flex {
        flex-wrap: wrap;
    }

    .tag-btn, .mode-btn {
        margin-bottom: 4px;
    }

    .boss-card {
        margin-bottom: 16px;
        padding: 16px !important;
        border-radius: 12px !important;
    }

    .boss-card img {
        height: 140px;
        object-fit: cover;
        border-radius: 10px;
    }

    .boss-card .h-32 {
        height: 140px !important; /* 移动端高度 */
        margin-bottom: 8px;
    }

    /* 移动端Boss属性标签优化 */
    .boss-details {
        margin-top: 8px !important;
        line-height: 1.4;
    }

    .boss-details span {
        font-size: 12px !important;
        padding: 3px 8px !important;
        margin-right: 4px !important;
        margin-bottom: 4px !important;
        display: inline-block;
        font-weight: 500;
    }

    /* 移动端Boss名称优化 */
    .boss-name {
        font-size: 16px !important;
        margin-top: 8px !important;
        margin-bottom: 4px !important;
        font-weight: 600;
    }

    /* 移动端计时器显示优化 */
    .countdown-display {
        font-size: 24px !important;
        margin-top: 10px !important;
        margin-bottom: 8px !important;
        font-weight: 800;
        line-height: 1.2;
    }

    .expiry-time {
        font-size: 14px !important;
        margin-bottom: 6px !important;
        font-weight: 600;
    }

    #boss-container,
    #hidden-bosses-content {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
    }

    .refresh-duration {
        font-size: 14px;
    }

    .flex.space-x-2 {
        flex-direction: column;
        gap: 8px;
    }

    .flex.space-x-2 > * {
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .hide-boss-btn {
        min-width: 70px;
        padding: 8px 16px !important;
        font-size: 13px !important;
        border-radius: 8px !important;
        margin-top: 12px !important;
    }

    .manual-time-input {
        margin-top: 16px !important;
    }

    .manual-time-input input {
        font-size: 18px !important;
        padding: 12px 16px !important;
        width: 120px !important;
        border-radius: 8px !important;
        border: 2px solid #d1d5db;
        text-align: center;
        font-weight: 600;
    }

    .manual-time-input input:focus {
        border-color: #3b82f6 !important;
        outline: none;
        box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    }

    .manual-time-input button {
        font-size: 16px !important;
        padding: 12px 20px !important;
        border-radius: 8px !important;
        min-height: 48px;
        font-weight: 600;
    }
}

@media (max-width: 640px) {
    .boss-card img {
        height: 120px;
        object-fit: cover;
        border-radius: 8px;
    }

    .boss-card .h-32 {
        height: 120px !important; /* 小屏幕高度 */
        margin-bottom: 6px;
    }

    .boss-card {
        padding: 14px !important;
        border-radius: 10px !important;
    }

    /* 小屏幕Boss属性标签进一步优化 */
    .boss-details span {
        font-size: 11px !important;
        padding: 2px 6px !important;
        margin-right: 3px !important;
        margin-bottom: 3px !important;
        border-radius: 8px !important;
        font-weight: 500;
    }

    .boss-name {
        font-size: 15px !important;
        margin-top: 6px !important;
        margin-bottom: 3px !important;
        font-weight: 600;
    }

    .countdown-display {
        font-size: 22px !important;
        margin-top: 8px !important;
        margin-bottom: 6px !important;
        font-weight: 800;
        line-height: 1.2;
    }

    .expiry-time {
        font-size: 13px !important;
        margin-bottom: 5px !important;
        font-weight: 600;
    }

    .text-lg {
        font-size: 16px !important;
    }

    .px-4 {
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    .py-2 {
        padding-top: 6px !important;
        padding-bottom: 6px !important;
    }

    .tag-btn, .mode-btn {
        font-size: 12px;
        padding: 6px 12px;
    }

    /* 小屏幕手动时间输入优化 */
    .manual-time-input input {
        width: 110px !important;
        font-size: 16px !important;
        padding: 10px 14px !important;
        border-radius: 8px !important;
        border: 2px solid #d1d5db;
        text-align: center;
        font-weight: 600;
    }

    .manual-time-input input:focus {
        border-color: #3b82f6 !important;
        outline: none;
        box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
    }

    .manual-time-input button {
        font-size: 14px !important;
        padding: 10px 16px !important;
        border-radius: 8px !important;
        min-height: 44px;
        font-weight: 600;
    }

    .hide-boss-btn {
        font-size: 12px !important;
        padding: 6px 12px !important;
        margin-top: 10px !important;
        border-radius: 8px !important;
    }

    /* 移动端分组快捷入口优化 */
    #groups-content .grid {
        grid-template-columns: 1fr !important;
        gap: 8px !important;
    }

    #groups-content .bg-white {
        padding: 12px !important;
    }

    #groups-content h3 {
        font-size: 14px !important;
        margin-bottom: 8px !important;
    }

    #groups-content .text-xs {
        font-size: 10px !important;
        padding: 2px 6px !important;
    }

    #groups-content .flex.gap-2 {
        flex-direction: column !important;
        gap: 6px !important;
    }

    #groups-content .flex.gap-2 a,
    #groups-content .flex.gap-2 button {
        width: 100% !important;
        text-align: center !important;
        font-size: 12px !important;
        padding: 6px 12px !important;
    }

    #groups-toggle {
        padding: 12px !important;
    }

    #groups-toggle span {
        font-size: 14px !important;
    }

    #groups-toggle .text-xs {
        font-size: 10px !important;
    }
}

/* 超小屏幕优化 */
@media (max-width: 480px) {
    .boss-card {
        padding: 12px !important;
        border-radius: 8px !important;
    }

    .boss-card img {
        height: 100px;
        object-fit: cover;
        border-radius: 6px;
    }

    .boss-card .h-32 {
        height: 100px !important;
        margin-bottom: 4px;
    }

    .boss-name {
        font-size: 14px !important;
        margin-top: 4px !important;
        margin-bottom: 2px !important;
        font-weight: 600;
    }

    .boss-details span {
        font-size: 10px !important;
        padding: 2px 5px !important;
        margin-right: 2px !important;
        margin-bottom: 2px !important;
        font-weight: 500;
    }

    .countdown-display {
        font-size: 20px !important;
        margin-top: 6px !important;
        margin-bottom: 5px !important;
        font-weight: 800;
        line-height: 1.2;
    }

    .expiry-time {
        font-size: 12px !important;
        margin-bottom: 4px !important;
        font-weight: 600;
    }

    .hide-boss-btn {
        font-size: 10px !important;
        padding: 3px 6px !important;
        margin-top: 4px !important;
    }

    .manual-time-input input {
        width: 100px !important;
        font-size: 14px !important;
        padding: 8px 12px !important;
        border-radius: 6px !important;
        border: 2px solid #d1d5db;
        text-align: center;
        font-weight: 600;
    }

    .manual-time-input input:focus {
        border-color: #3b82f6 !important;
        outline: none;
        box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
    }

    .manual-time-input button {
        font-size: 12px !important;
        padding: 8px 14px !important;
        border-radius: 6px !important;
        min-height: 40px;
        font-weight: 600;
    }

    /* 超小屏幕分组入口优化 */
    #groups-toggle {
        padding: 8px !important;
    }

    #groups-toggle span {
        font-size: 13px !important;
    }

    #groups-content .bg-white {
        padding: 8px !important;
    }

    #groups-content h3 {
        font-size: 13px !important;
    }

    #groups-content .text-xs {
        font-size: 10px !important;
        padding: 2px 5px !important;
    }

    #groups-content .flex.gap-2 a,
    #groups-content .flex.gap-2 button {
        font-size: 12px !important;
        padding: 5px 10px !important;
    }
}
