/* ═══════════════════════════════════════════════════════════════
   PORTED APP CHROME — Windows Media Player skin, Live Stream gate,
   Portfolio, Contact, Snake. Appended after the main XP stylesheet.
   ═══════════════════════════════════════════════════════════════ */

/* ─── Password modal (Live Stream gate) ─── */
@keyframes xp-shake {
    0%,
    100% {
        transform: translateX(0);
    }
    10%,
    30%,
    50%,
    70%,
    90% {
        transform: translateX(-6px);
    }
    20%,
    40%,
    60%,
    80% {
        transform: translateX(6px);
    }
}
.modal-window {
    min-width: 280px;
    min-height: 120px;
    padding: 0;
    box-shadow: 2px 2px 8px rgba(0, 0, 0, 0.6);
}
.modal-window .window-body {
    padding: 15px;
    font-size: 12px;
    background: #ece9d8;
}
.modal-window.shake {
    animation: xp-shake 0.4s ease-in-out;
}
.stream-password-input {
    width: 100%;
    padding: 3px 5px;
    border: 2px inset #d4d0c8;
    font-family: Tahoma, sans-serif;
    font-size: 12px;
    background: #fff;
    outline: none;
    box-sizing: border-box;
}
.stream-password-input:focus {
    border-color: #0055ee;
}
.stream-error-text {
    color: #cc0000;
    font-size: 11px;
    margin-top: 6px;
    display: none;
    text-align: center;
}
.stream-error-text.visible {
    display: block;
}
.window-toolbar-button {
    font-family: Tahoma, sans-serif;
    font-size: 11px;
    padding: 3px 14px;
    border: 1px solid #003c74;
    border-radius: 3px;
    background: linear-gradient(180deg, #fff 0%, #ece9d8 60%, #d4d0c8 100%);
    cursor: pointer;
}
.window-toolbar-button:active {
    background: #d4d0c8;
}

/* ─── Portfolio ─── */
.portfolio-wrap {
    flex: 1;
    min-height: 0;
    display: flex;
    flex-direction: column;
    background: #fff;
    font-family: Tahoma, sans-serif;
}
.portfolio-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding: 10px 12px 8px;
    border-bottom: 1px solid #ccc;
    background: linear-gradient(180deg, #fff, #f1efe7);
}
.portfolio-title {
    font-size: 15px;
    font-weight: bold;
    color: #003399;
}
.portfolio-sub {
    font-size: 11px;
    color: #777;
}
.portfolio-grid {
    flex: 1;
    overflow: auto;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 12px;
    padding: 12px;
}
.portfolio-card {
    border: 1px solid #c8c4b8;
    border-radius: 4px;
    background: #fbfaf7;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 1px 1px 4px rgba(0, 0, 0, 0.15);
}
.portfolio-card-media {
    height: 260px;
    background: #111;
    border-bottom: 1px solid #c8c4b8;
}
.portfolio-card-body {
    padding: 8px 10px 10px;
    font-size: 12px;
}
.portfolio-card-caption {
    font-size: 11px;
    color: #666;
    margin-top: 3px;
}
.portfolio-empty {
    padding: 24px;
    font-size: 12px;
    color: #666;
}
.portfolio-empty code {
    background: #f1efe7;
    padding: 1px 4px;
    border: 1px solid #ddd;
}
.window.dark-mode .portfolio-wrap {
    background: #1b1b1b;
}
.window.dark-mode .portfolio-head {
    background: #252525;
    border-color: #444;
}
.window.dark-mode .portfolio-title {
    color: #8bb8f8;
}
.window.dark-mode .portfolio-card {
    background: #232323;
    border-color: #444;
}
.window.dark-mode .portfolio-card-caption {
    color: #aaa;
}

/* ─── Contact card ─── */
.contact-card {
    flex: 1;
    background: #fff;
    padding: 18px;
    font-family: Tahoma, sans-serif;
    font-size: 12px;
    overflow: auto;
}
.contact-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}
.contact-avatar {
    width: 56px;
    height: 56px;
    image-rendering: pixelated;
}
.contact-head h2 {
    margin: 0;
    font-size: 18px;
}
.contact-head p {
    margin: 2px 0 0;
    color: #666;
    font-size: 12px;
}
.contact-rows {
    border-top: 1px solid #ccc;
    padding-top: 10px;
}
.contact-rows p {
    margin: 6px 0;
}
.contact-online {
    color: #10893e;
    font-weight: bold;
}
.contact-socials {
    margin-top: 16px;
    border-top: 1px solid #ccc;
    padding-top: 10px;
}
.contact-socials-title {
    font-size: 11px;
    text-transform: uppercase;
    color: #888;
    margin-bottom: 6px;
}
.contact-social {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    margin: 0 12px 8px 0;
    color: #0a246a;
    text-decoration: none;
    font-size: 12px;
}
.contact-social:hover {
    text-decoration: underline;
}
.contact-social img {
    width: 20px;
    height: 20px;
    image-rendering: pixelated;
}
.window.dark-mode .contact-card {
    background: #1b1b1b;
    color: #ddd;
}
.window.dark-mode .contact-rows,
.window.dark-mode .contact-socials {
    border-color: #444;
}
.window.dark-mode .contact-social {
    color: #8bb8f8;
}

/* ─── Snake ─── */
.snake-frame {
    flex: 1;
    width: 100%;
    min-height: 0;
    border: none;
    display: block;
    background: #0a0f0a;
}

/* ─── Mobile: give the ported apps room on small screens ─── */
@media (max-width: 768px) {
    .portfolio-card-media {
        height: 200px;
    }
}

/* ═══════════════ Internet Explorer (apps/browser.js) ═══════════════ */
.ie-window {
    min-width: 260px;
}

.ie-chrome {
    flex-shrink: 0;
    background: #ece9d8;
    border-bottom: 1px solid #aca899;
}

.window.dark-mode .ie-chrome {
    background: #2d2d30;
    border-color: #444;
}

/* menus */
.ie-menubar {
    position: relative;
    display: flex;
    gap: 2px;
    padding: 2px 4px;
    font-size: 11px;
    background: #f1efe2;
    border-bottom: 1px solid #d8d4c8;
}
.window.dark-mode .ie-menubar {
    background: #333;
    border-color: #444;
}
.ie-menu {
    padding: 2px 8px;
    cursor: default;
    color: #222;
}
.window.dark-mode .ie-menu {
    color: #ccc;
}
.ie-menu:hover {
    background: #0a246a;
    color: #fff;
}
.ie-menu-dd {
    position: absolute;
    top: 100%;
    left: 0;
    z-index: 30;
    min-width: 210px;
    background: #fff;
    border: 1px solid #808080;
    box-shadow: 2px 2px 6px rgba(0, 0, 0, 0.35);
}
.window.dark-mode .ie-menu-dd {
    background: #2d2d30;
    border-color: #555;
}
.ie-dd-item {
    display: flex;
    align-items: center;
    gap: 7px;
    padding: 5px 14px;
    font-size: 11px;
    cursor: pointer;
    color: #222;
    white-space: nowrap;
}
.window.dark-mode .ie-dd-item {
    color: #ccc;
}
.ie-dd-item img {
    width: 14px;
    height: 14px;
}
.ie-dd-item:hover {
    background: #0a246a;
    color: #fff;
}

/* tabs */
.ie-tabstrip {
    display: flex;
    align-items: flex-end;
    gap: 3px;
    padding: 4px 6px 0;
    background: #dfe3ea;
    border-bottom: 1px solid #aca899;
    overflow-x: auto;
    scrollbar-width: thin;
}
.window.dark-mode .ie-tabstrip {
    background: #3a3a3d;
    border-color: #555;
}
.ie-tabs {
    display: flex;
    gap: 3px;
    overflow: hidden;
}
.ie-tab {
    display: flex;
    align-items: center;
    gap: 5px;
    max-width: 170px;
    min-width: 90px;
    padding: 4px 6px 4px 8px;
    font-size: 10.5px;
    color: #333;
    background: linear-gradient(#f5f4ef, #ddd8ca);
    border: 1px solid #aca899;
    border-bottom: none;
    border-radius: 6px 6px 0 0;
    cursor: pointer;
    flex-shrink: 0;
}
.window.dark-mode .ie-tab {
    background: linear-gradient(#4a4a4e, #3a3a3d);
    color: #ccc;
    border-color: #555;
}
.ie-tab.on {
    background: #fff;
    font-weight: bold;
    margin-bottom: -1px;
    padding-bottom: 5px;
}
.window.dark-mode .ie-tab.on {
    background: #2d2d30;
}
.ie-tab img {
    width: 14px;
    height: 14px;
    flex-shrink: 0;
}
.ie-tab-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ie-tab-x {
    border: none;
    background: transparent;
    color: #666;
    cursor: pointer;
    font-size: 9px;
    padding: 1px 3px;
    border-radius: 3px;
    line-height: 1;
}
.window.dark-mode .ie-tab-x {
    color: #999;
}
.ie-tab-x:hover {
    background: #c94a4a;
    color: #fff;
}
.ie-newtab {
    border: 1px solid #aca899;
    background: linear-gradient(#fbfaf7, #ddd8ca);
    border-radius: 4px 4px 0 0;
    font-size: 12px;
    cursor: pointer;
    padding: 2px 8px 3px;
    color: #333;
}
.window.dark-mode .ie-newtab {
    background: #4a4a4e;
    border-color: #555;
    color: #ccc;
}

/* toolbar + address bar */
.ie-toolbar {
    display: flex;
    gap: 3px;
    padding: 4px 6px;
}
.ie-btn {
    border: 1px solid transparent;
    border-radius: 3px;
    background: transparent;
    font-size: 11px;
    color: #1a1a1a;
    padding: 3px 8px;
    cursor: pointer;
    white-space: nowrap;
}
.window.dark-mode .ie-btn {
    color: #ccc;
}
.ie-btn:hover {
    background: linear-gradient(#fdfdfc, #e6f1fd);
    border-color: #7da2ce;
}
.window.dark-mode .ie-btn:hover {
    background: #4a4a4e;
    border-color: #666;
}
.ie-btn:active {
    background: linear-gradient(#dfe3ea, #d0d0d0);
}

.ie-address {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 3px 6px 6px;
}
.ie-address > span {
    font-size: 11px;
    color: #333;
    background: #dfe3ea;
    border: 1px solid #aca899;
    padding: 3px 6px;
    border-radius: 2px;
    flex-shrink: 0;
}
.window.dark-mode .ie-address > span {
    background: #3a3a3d;
    border-color: #555;
    color: #bbb;
}
.ie-address input {
    flex: 1;
    min-width: 60px;
    border: 1px solid #7f9db9;
    padding: 4px 6px;
    font-size: 11px;
    outline: none;
    user-select: text;
    -webkit-user-select: text;
}
.window.dark-mode .ie-address input {
    background: #1e1e1e;
    border-color: #555;
    color: #ddd;
}
.ie-ext {
    flex-shrink: 0;
    color: #0a246a !important;
}
.window.dark-mode .ie-ext {
    color: #8bb8f8 !important;
}

/* views */
.ie-views {
    position: relative;
    flex: 1;
    min-height: 0;
    background: #fff;
}
.ie-frame {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: none;
    display: none;
    background: #fff;
}

/* status bar */
.ie-status {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 10.5px;
    color: #333;
    background: #d4d2c8;
    border-top: 1px solid #fff;
    padding: 3px 8px;
    min-height: 18px;
}
.window.dark-mode .ie-status {
    background: #3a3a3d;
    color: #bbb;
    border-color: #555;
}
.ie-status-txt {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ie-zone {
    color: #555;
    border-left: 1px solid #b0aea2;
    padding-left: 8px;
    flex-shrink: 0;
}
.window.dark-mode .ie-zone {
    color: #999;
    border-color: #555;
}
