/* =============================================
   じゃらん风格模板 - 橙色品牌 / 蓝色按钮 / 白色主体
   class前缀: jr-  避免与前四套重叠
   ============================================= */

:root {
    --jr-orange:     #f07800;
    --jr-orange-d:   #d46400;
    --jr-orange-l:   #fff4e6;
    --jr-orange-ll:  #fffaf3;
    --jr-blue:       #3a7bd5;
    --jr-blue-d:     #2a5fa8;
    --jr-blue-l:     #e8f0fb;
    --jr-line:       #e0e0e0;
    --jr-line-l:     #efefef;
    --jr-fg:         #333333;
    --jr-fg-2:       #555555;
    --jr-fg-3:       #999999;
    --jr-bg:         #f4f4f4;
    --jr-white:      #ffffff;
    --jr-cover:      calc(350 / 600 * 100%);
    --jr-rd:         6px;
    --jr-rd-sm:      4px;
    --jr-rd-pill:    22px;
    --jr-shadow:     0 1px 4px rgba(0,0,0,0.09);
    --jr-ease:       all 0.17s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { overflow-x: hidden; max-width: 100vw; }
body {
    font-family: 'Helvetica Neue', Arial, 'PingFang TC', 'Microsoft YaHei', sans-serif;
    background: var(--jr-bg);
    color: var(--jr-fg);
    font-size: 14px;
    line-height: 1.6;
    overflow-x: hidden;
    max-width: 100vw;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
ul, ol { list-style: none; }
.jrcfix::after { content: ''; display: table; clear: both; }

/* layout */
.jrw {
    max-width: 1050px;
    width: 100%;
    margin: 0 auto;
    padding: 0 14px;
    box-sizing: border-box;
    overflow-x: hidden;
}
.jrw * { box-sizing: border-box; max-width: 100%; }

/* ══ HEADER ══ */
.jr-header {
    background: var(--jr-orange);
    box-shadow: 0 2px 6px rgba(0,0,0,0.18);
}
.jr-header-inner {
    max-width: 1050px;
    margin: 0 auto;
    padding: 0 14px;
    display: flex;
    align-items: center;
    height: 60px;
    gap: 12px;
}
.jr-logo-link {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    flex-shrink: 0;
}
.jr-logo-badge {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--jr-white);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}
.jr-logo-badge-text {
    font-size: 10px;
    font-weight: 900;
    color: var(--jr-orange);
    line-height: 1.1;
    text-align: center;
    letter-spacing: -0.5px;
}
.jr-site-info {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 3px;
}
.jr-site-name {
    font-size: 19px;
    font-weight: 900;
    color: var(--jr-white);
    line-height: 1.1;
    letter-spacing: -0.3px;
}
.jr-domain-row {
    display: flex;
    align-items: center;
    gap: 7px;
}
.jr-domain-lbl {
    font-size: 10px;
    color: rgba(255,255,255,0.88);
    font-weight: 700;
    letter-spacing: 0.3px;
    white-space: nowrap;
    background: rgba(0,0,0,0.18);
    padding: 2px 7px;
    border-radius: 10px;
    flex-shrink: 0;
}
.jr-domain-val {
    font-size: 16px;
    font-weight: 900;
    color: var(--jr-white);
    font-family: 'Courier New', monospace;
    letter-spacing: 0.2px;
    text-shadow: 0 1px 4px rgba(0,0,0,0.25);
}

/* ══ NAV ══ */
.jr-nav-zone {
    background: var(--jr-white);
    border-bottom: 2px solid var(--jr-orange);
    box-shadow: var(--jr-shadow);
}
.jr-nav-zone .jrw { padding: 0 14px; }

.jr-nav-row {
    display: flex;
    align-items: stretch;
    border-bottom: 1px solid var(--jr-line-l);
    min-height: 34px;
}
.jr-nav-row:last-child { border-bottom: none; }

.jr-nav-lbl {
    width: 10%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--jr-white);
    background: var(--jr-orange);
    padding: 5px 3px;
    white-space: nowrap;
    border-right: 3px solid var(--jr-orange-d);
}
.jr-nav-links {
    width: 90%;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 2px;
    padding: 5px 8px;
}
.jr-nav-links a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: calc((100% - 28px) / 8);
    padding: 4px 2px;
    font-size: 13px;
    color: var(--jr-fg-2);
    border-radius: var(--jr-rd-sm);
    transition: var(--jr-ease);
    white-space: nowrap;
    text-align: center;
    border: 1px solid transparent;
}
.jr-nav-links a:hover,
.jr-nav-links a.active {
    color: var(--jr-orange-d);
    background: var(--jr-orange-l);
    border-color: rgba(240,120,0,0.22);
    font-weight: 700;
}

/* ══ SEARCH ══ */
.jr-search-wrap {
    background: var(--jr-orange-l);
    border-bottom: 1px solid #e8c888;
    padding: 7px 0;
}
.jr-search-wrap .jrw { padding: 0 14px; }
.jr-search-form {
    display: flex;
    gap: 6px;
    align-items: center;
    flex-wrap: nowrap;
}
.jr-search-form input[type="text"] {
    flex: 1;
    min-width: 80px;
    height: 38px;
    padding: 0 14px;
    border: 1.5px solid #d0b080;
    border-radius: var(--jr-rd);
    background: var(--jr-white);
    font-size: 14px;
    color: var(--jr-fg);
    outline: none;
    transition: var(--jr-ease);
}
.jr-search-form input[type="text"]::placeholder { color: var(--jr-fg-3); }
.jr-search-form input[type="text"]:focus {
    border-color: var(--jr-blue);
    box-shadow: 0 0 0 2px rgba(58,123,213,0.14);
}
.jr-search-form button {
    height: 38px;
    padding: 0 15px;
    border: none;
    border-radius: var(--jr-rd);
    background: var(--jr-blue);
    color: var(--jr-white);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    transition: var(--jr-ease);
    box-shadow: 0 2px 4px rgba(58,123,213,0.28);
}
.jr-search-form button:hover { background: var(--jr-blue-d); }

/* ══ HOT TAGS ══ */
.jr-hot-panel {
    background: var(--jr-white);
    border-bottom: 1px solid var(--jr-line-l);
    padding: 6px 0;
}
.jr-hot-panel .jrw { padding: 0 14px; }
.jr-hot-inner {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}
.jr-hot-lbl {
    font-size: 11px;
    font-weight: 700;
    color: var(--jr-white);
    background: var(--jr-orange);
    padding: 3px 9px;
    border-radius: var(--jr-rd-sm);
    white-space: nowrap;
    flex-shrink: 0;
}
.jr-hot-tags { display: flex; flex-wrap: wrap; gap: 4px; }
.jr-tag {
    display: inline-block;
    padding: 3px 10px;
    background: var(--jr-white);
    color: var(--jr-fg-2);
    font-size: 12px;
    border-radius: var(--jr-rd-pill);
    border: 1px solid var(--jr-line);
    transition: var(--jr-ease);
    white-space: nowrap;
}
.jr-tag:hover {
    background: var(--jr-orange-l);
    color: var(--jr-orange-d);
    border-color: var(--jr-orange);
}

/* ══ MAIN ══ */
.jr-main { padding: 5px 0; }

.jr-section {
    background: var(--jr-white);
    margin-bottom: 5px;
    border: 1px solid var(--jr-line);
    border-radius: var(--jr-rd);
    overflow: hidden;
    box-shadow: var(--jr-shadow);
}
.jr-section-head {
    background: linear-gradient(to right, var(--jr-orange-l), var(--jr-white));
    border-bottom: 2px solid var(--jr-orange);
    padding: 8px 14px;
    display: flex;
    align-items: center;
    gap: 8px;
}
.jr-section-head::before {
    content: '';
    display: inline-block;
    width: 4px;
    height: 17px;
    background: var(--jr-orange);
    border-radius: 2px;
    flex-shrink: 0;
}
.jr-section-title { font-size: 15px; font-weight: 700; color: var(--jr-fg); margin: 0; }
.jr-section-title a { color: var(--jr-fg); transition: var(--jr-ease); }
.jr-section-title a:hover { color: var(--jr-orange); }
.jr-section-body { padding: 12px 14px; }

/* ── grid ── */
.jr-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
    list-style: none;
    padding: 0;
    margin: 0;
}
.jr-grid li { min-width: 0; }

.jr-thumb {
    display: block;
    position: relative;
    padding-top: var(--jr-cover);
    overflow: hidden;
    border-radius: var(--jr-rd-sm);
    background: var(--jr-line-l);
    width: 100%;
}
.jr-thumb img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}
.jr-thumb:hover img { transform: scale(1.04); }
.jr-thumb::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.3) 0%, transparent 50%);
    opacity: 0;
    transition: opacity 0.3s;
}
.jr-thumb:hover::after { opacity: 1; }

.jr-card-info { padding: 5px 0 0; }
.jr-card-info h5 { margin: 0; font-size: 12px; font-weight: 500; line-height: 1.45; }
.jr-card-info h5 a {
    color: var(--jr-fg-2);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: var(--jr-ease);
}
.jr-card-info h5 a:hover { color: var(--jr-orange); }

/* ── pagination ── */
.jr-page-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 4px;
    flex-wrap: wrap;
    padding: 12px 0;
}
.jr-pg, .jr-pg-cur {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 34px;
    height: 34px;
    padding: 0 10px;
    font-size: 13px;
    font-weight: 600;
    border-radius: var(--jr-rd-sm);
    transition: var(--jr-ease);
}
.jr-pg { background: var(--jr-white); color: var(--jr-fg-2); border: 1px solid var(--jr-line); }
.jr-pg:hover { background: var(--jr-blue-l); color: var(--jr-blue); border-color: var(--jr-blue); }
.jr-pg-cur { background: var(--jr-blue); color: var(--jr-white); border: 1px solid var(--jr-blue-d); cursor: default; }

/* ══ PLAYER (overflow-safe) ══ */
.jr-player-shell {
    width: 100%; max-width: 100%; overflow: hidden; box-sizing: border-box; margin-bottom: 6px;
}
.jr-player-shell * { max-width: 100% !important; box-sizing: border-box !important; }
.jr-player-shell > * { width: 100% !important; }

.MacPlayer { width: 100% !important; max-width: 100% !important; overflow: hidden; box-sizing: border-box; }
.MacPlayer > div, .MacPlayer > table, .MacPlayer > iframe, .MacPlayer > video {
    width: 100% !important; max-width: 100% !important; box-sizing: border-box !important;
}
.video-container {
    width: 100%; max-width: 100%; height: 600px; max-height: 600px;
    overflow: hidden; background: #000; border-radius: var(--jr-rd); position: relative; box-sizing: border-box;
}
.video-container iframe, .video-container video, .video-container #video-container {
    width: 100% !important; max-width: 100% !important; height: 100%; border: none;
}

/* ── detail bar ── */
.jr-detail-bar {
    background: var(--jr-white);
    border-left: 4px solid var(--jr-orange);
    padding: 10px 14px;
    font-size: 15px;
    font-weight: 500;
    line-height: 1.6;
    word-break: break-all;
    overflow-wrap: break-word;
    margin-bottom: 5px;
    max-width: 100%;
    overflow: hidden;
    border-radius: var(--jr-rd);
    box-shadow: var(--jr-shadow);
}
.jr-detail-bar a { color: var(--jr-orange); font-weight: 700; margin-right: 6px; font-size: 13px; }

/* ── torrent info ── */
.jr-torrent-info {
    background: var(--jr-white);
    padding: 14px 16px;
    font-size: 14px;
    line-height: 1.9;
    word-break: break-all;
    overflow-wrap: break-word;
    overflow: hidden;
    max-width: 100%;
    margin-bottom: 5px;
    border-radius: var(--jr-rd);
    border: 1px solid var(--jr-line);
    box-shadow: var(--jr-shadow);
}
.jr-capture-grid { width: 100%; overflow: hidden; }
.jr-capture-grid picture { display: block; width: 100%; }
.jr-capture-grid picture img { width: 100%; height: auto; max-width: 100%; display: block; }
.jr-capture-grid img { width: 100%; height: auto; max-width: 100%; display: block; }
.jr-capture-grid .img_item { width: 100%; }
.jr-capture-grid .img_item img { width: 100%; }

/* ── download buttons ── */
.jr-dl-row {
    display: flex; justify-content: center; align-items: center; flex-wrap: wrap;
    gap: 10px; padding: 12px 14px; background: var(--jr-white);
    margin-bottom: 5px; border-radius: var(--jr-rd); border: 1px solid var(--jr-line);
}
.jr-dl-btn {
    display: inline-flex; align-items: center; justify-content: center;
    padding: 9px 26px; background: var(--jr-blue); color: var(--jr-white);
    font-size: 14px; font-weight: 700; border: none; border-radius: var(--jr-rd-pill);
    cursor: pointer; transition: var(--jr-ease); white-space: nowrap; text-decoration: none;
    box-shadow: 0 2px 5px rgba(58,123,213,0.3);
}
.jr-dl-btn:hover { background: var(--jr-blue-d); transform: translateY(-1px); }

.jr-client-link { text-align: center; padding: 5px 0 8px; }
.jr-client-link a { color: var(--jr-blue); font-size: 13px; font-weight: 700; border-bottom: 1px dashed var(--jr-blue); transition: var(--jr-ease); }
.jr-client-link a:hover { color: var(--jr-blue-d); }

/* ── share ── */
.jr-share-row {
    display: flex; align-items: center; gap: 8px; background: var(--jr-white);
    padding: 10px 14px; margin-bottom: 5px; border-radius: var(--jr-rd);
    border: 1px solid var(--jr-line); min-width: 0; overflow: hidden; max-width: 100%;
}
.jr-share-url-box {
    display: flex; align-items: center; gap: 7px; flex: 1 1 0; min-width: 0; overflow: hidden;
    background: var(--jr-bg); border: 1px solid var(--jr-line); border-radius: var(--jr-rd-pill); padding: 6px 14px;
}
.jr-share-lbl { font-size: 10px; font-weight: 700; color: var(--jr-orange); white-space: nowrap; flex-shrink: 0; text-transform: uppercase; letter-spacing: 0.4px; }
.jr-share-url {
    font-size: 12px; color: var(--jr-fg-2); font-family: 'Courier New', monospace;
    min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; word-break: break-all; flex: 1;
}
.jr-share-btn {
    display: inline-flex; align-items: center; gap: 5px;
    padding: 8px 16px; background: var(--jr-blue); color: var(--jr-white);
    font-size: 13px; font-weight: 700; border: none; border-radius: var(--jr-rd-pill);
    cursor: pointer; white-space: nowrap; flex-shrink: 0; transition: var(--jr-ease);
}
.jr-share-btn:hover { background: var(--jr-blue-d); }

/* ── flink ── */
.jr-flink-section {
    background: var(--jr-white); margin-bottom: 5px; border: 1px solid var(--jr-line);
    border-radius: var(--jr-rd); padding: 10px 14px; box-shadow: var(--jr-shadow);
}
.jr-flink-title { font-size: 13px; font-weight: 700; color: var(--jr-fg-3); margin-bottom: 6px; padding-left: 8px; border-left: 3px solid var(--jr-orange); }
.jr-flink-section dl { margin: 0; }
.jr-flink-section dd { display: inline-block; margin: 2px 5px; }
.jr-flink-section a { font-size: 12px; color: var(--jr-fg-3); transition: var(--jr-ease); }
.jr-flink-section a:hover { color: var(--jr-orange); }

/* ── footer ── */
.jr-footer { background: #444; border-top: 3px solid var(--jr-orange); padding: 14px 0; text-align: center; margin-top: 5px; }
.jr-footer p { color: rgba(255,255,255,0.38); font-size: 11px; margin: 3px 0; }
.jr-footer a { color: rgba(255,255,255,0.38); transition: var(--jr-ease); }
.jr-footer a:hover { color: rgba(255,255,255,0.75); }

/* ── hide ── */
.jrh-mo { display: block; }
.jrh-pc { display: block; }
@media (max-width: 768px)  { .jrh-mo { display: none !important; } }
@media (min-width: 769px)  { .jrh-pc { display: none !important; } }

/* ══ RESPONSIVE ══ */
@media (max-width: 768px) {
    .jrw { padding: 0 8px; }
    .jr-header-inner { height: 50px; padding: 0 8px; gap: 8px; }
    .jr-logo-badge { width: 38px; height: 38px; }
    .jr-logo-badge-text { font-size: 9px; }
    .jr-site-name { font-size: 15px; }
    .jr-domain-lbl { font-size: 8px; padding: 1px 5px; }
    .jr-domain-val { font-size: 13px; }

    /* Nav: label 15% links 85%, 4/row */
    .jr-nav-lbl { width: 15%; font-size: 10px; padding: 5px 2px; border-right-width: 2px; }
    .jr-nav-links { width: 85%; padding: 4px 4px; gap: 3px; }
    .jr-nav-links a { width: calc((100% - 9px) / 4); font-size: 12px; padding: 4px 1px; }

    .jr-grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
    .jr-search-form input[type="text"] { height: 34px; font-size: 13px; }
    .jr-search-form button { height: 34px; padding: 0 10px; font-size: 12px; }
    .video-container { height: 56.25vw; max-height: 340px; }
    .jr-section-head { padding: 7px 10px; }
    .jr-section-title { font-size: 14px; }
    .jr-section-body { padding: 10px; }
    .jr-detail-bar { font-size: 13px; padding: 9px 10px; }
    .jr-dl-row { padding: 10px 8px; gap: 8px; }
    .jr-dl-btn { padding: 8px 18px; font-size: 13px; }
    .jr-share-row { padding: 8px 10px; gap: 6px; }
    .jr-share-url-box { padding: 5px 10px; }
    .jr-share-lbl { font-size: 9px; }
    .jr-share-url { font-size: 10px; }
    .jr-share-btn { padding: 7px 12px; font-size: 12px; }
    .jr-pg, .jr-pg-cur { min-width: 30px; height: 30px; font-size: 12px; }
    .jr-hot-lbl { font-size: 11px; padding: 2px 7px; }
    .jr-tag { font-size: 11px; padding: 2px 8px; }
    .jr-card-info h5 { font-size: 11px; }
    .jr-flink-section { padding: 8px 10px; }
    .jr-footer { padding: 10px 0; }
}
@media (min-width: 481px) and (max-width: 768px) {
    .jr-nav-links a { font-size: 14px; }
}
@media (max-width: 480px) {
    .jr-header-inner { height: 46px; }
    .jr-logo-badge { width: 34px; height: 34px; }
    .jr-site-name { font-size: 13px; }
    .jr-domain-val { font-size: 12px; }
    .jr-nav-lbl { width: 15%; font-size: 10px; }
    .jr-nav-links { width: 85%; }
    .jr-nav-links a { width: calc((100% - 9px) / 4); font-size: 12px; }
    .jr-grid { grid-template-columns: repeat(2, 1fr); gap: 7px; }
}
@media (min-width: 769px) {
    .jr-grid { grid-template-columns: repeat(4, 1fr); }
    .jr-nav-lbl { font-size: 12px; }
    .jr-nav-links a { font-size: 13px; width: calc((100% - 28px) / 8); }
}
