/* Windows 95 Style CSS with Emo/Goth aesthetic */

/* Taskbar */
.taskbar {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 30px;
    background-color: var(--window-color);
    border-top: 2px solid #FFFFFF;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 9999;
    box-shadow: 0 -2px 10px rgba(147, 50, 204, 0.3);
}

.start-button {
    display: flex;
    align-items: center;
    height: 22px;
    padding: 0 5px;
    margin-left: 2px;
    background-color: var(--window-color);
    border-top: 1px solid #000;
    border-left: 1px solid #000;
    border-right: 1px solid #FFF;
    border-bottom: 1px solid #FFF;
    font-weight: bold;
    color: #000;
    cursor: pointer;
    transition: all 0.1s ease;
}

.start-button:hover {
    background-color: #D0D0D0;
    box-shadow: 0 0 5px rgba(147, 50, 204, 0.5);
}

.start-button:active {
    border-top: 1px solid #FFF;
    border-left: 1px solid #FFF;
    border-right: 1px solid #000;
    border-bottom: 1px solid #000;
    transform: translateY(1px);
}

.clock {
    padding: 0 10px;
    font-size: 0.8rem;
    color: #000;
    text-shadow: 0 0 2px rgba(75, 0, 130, 0.3);
}

/* Windows */
.window {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 80%;
    height: 80%;
    background-color: var(--window-color);
    border: 2px solid var(--window-border);
    box-shadow: 
        2px 2px 10px rgba(0, 0, 0, 0.5),
        0 0 20px rgba(147, 50, 204, 0.2);
    display: flex;
    flex-direction: column;
    overflow: hidden;
    z-index: 2;
    image-rendering: pixelated;
    transition: box-shadow 0.3s ease;
}

.window::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFElEQVQImWNgYGD4z8DAwMDAxAADACIDAgHnOxvbAAAAAElFTkSuQmCC');
    background-repeat: repeat;
    opacity: 0.05;
    pointer-events: none;
}

.window:hover {
    box-shadow: 
        2px 2px 10px rgba(0, 0, 0, 0.6),
        0 0 30px rgba(147, 50, 204, 0.3);
}

.window-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 25px;
    background: linear-gradient(90deg, var(--deep-violet) 0%, var(--violet) 50%, var(--deep-violet) 100%);
    padding: 0 5px;
    cursor: move;
    position: relative;
    overflow: hidden;
}

.window-header::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, 
        transparent 0%, 
        rgba(255, 255, 255, 0.5) 50%, 
        transparent 100%);
}

.window-title {
    color: white;
    font-weight: bold;
    font-size: 0.9rem;
    text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.7);
    letter-spacing: 0.5px;
}

.window-controls {
    display: flex;
}

.window-controls button {
    width: 20px;
    height: 20px;
    margin-left: 2px;
    background-color: var(--window-color);
    border: 1px outset var(--window-border);
    color: #000;
    font-size: 12px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    transition: all 0.1s ease;
    position: relative;
    z-index: 2;
}

/* 閉じるボタン - 元のサイズに戻す */
.window-controls .close {
    width: 20px;
    height: 20px;
    font-size: 12px;
    font-weight: bold;
    color: #900;
    background-color: #ddd;
    position: relative;
}

/* 閉じるボタンのホバー効果 */
.window-controls .close:hover {
    background-color: #f55;
    color: white;
    box-shadow: 0 0 8px var(--pink);
}

.window-controls button:hover {
    background-color: #D0D0D0;
    box-shadow: 0 0 3px rgba(147, 50, 204, 0.5);
}

.window-controls button:active {
    border: 1px inset var(--window-border);
    transform: translateY(1px);
}

/* 閉じるボタンのアニメーション */
@keyframes pulse-close {
    0% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(255, 105, 180, 0.7);
    }
    50% {
        transform: scale(1.1);
        box-shadow: 0 0 10px rgba(255, 105, 180, 0.9);
    }
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 rgba(255, 105, 180, 0.7);
    }
}

.window-controls .close.pulse-animation {
    animation: pulse-close 1s ease;
}

/* モバイル向けのタッチ領域拡大 */
@media (max-width: 768px) {
    .window-controls button {
        width: 24px;
        height: 24px;
        margin-left: 3px;
        font-size: 14px;
        position: relative;
    }
    
    /* 閉じるボタンのスタイル：大きさを他のボタンと同じにする */
    .window-controls .close {
        width: 24px;
        height: 24px;
        font-size: 14px;
    }
    
    /* タップ領域を拡大するための疑似要素 */
    .window-controls button::before {
        content: "";
        position: absolute;
        top: -10px;
        left: -10px;
        right: -10px;
        bottom: -10px;
        z-index: 1;
        pointer-events: auto;
        background-color: transparent;
    }
    
    .window-header {
        height: 30px;
        padding: 0 8px;
    }
    
    .desktop::after {
        background: 
            radial-gradient(circle at 20% 30%, rgba(255, 215, 0, 0.2) 0%, transparent 40%),
            radial-gradient(circle at 80% 20%, rgba(255, 105, 180, 0.2) 0%, transparent 40%),
            radial-gradient(circle at 50% 50%, rgba(0, 191, 255, 0.15) 0%, transparent 60%);
    }
}

/* スマートフォン用のスタイル - より小さい画面向け */
@media (max-width: 480px) {
    .window-controls .close {
        width: 18px;
        height: 18px;
        font-size: 10px;
    }
    
    .window-controls button {
        width: 18px;
        height: 18px;
        font-size: 10px;
    }
    
    .window-header {
        height: 25px;
    }
    
    .window-title {
        font-size: 0.8rem;
    }
}

.window-menu {
    display: flex;
    background-color: var(--window-color);
    border-bottom: 1px solid var(--window-border);
    position: relative;
}

.window-menu::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFElEQVQImWNgYGD4z8DAwMDAxAADACIDAgHnOxvbAAAAAElFTkSuQmCC');
    background-repeat: repeat;
    opacity: 0.05;
    pointer-events: none;
}

.menu-item {
    padding: 2px 10px;
    font-size: 0.8rem;
    color: #000;
    cursor: pointer;
    position: relative;
    z-index: 1;
    transition: all 0.1s ease;
}

.menu-item:hover {
    background-color: var(--violet);
    color: white;
    text-shadow: 0 0 2px rgba(255, 255, 255, 0.5);
}

.window-content {
    flex: 1;
    display: flex;
    overflow: auto;
    position: relative;
}

.window-statusbar {
    height: 20px;
    background-color: var(--window-color);
    border-top: 1px solid var(--window-border);
    padding: 2px 5px;
    font-size: 0.8rem;
    color: #000;
    display: flex;
    align-items: center;
    position: relative;
}

.window-statusbar::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-image: url('data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFElEQVQImWNgYGD4z8DAwMDAxAADACIDAgHnOxvbAAAAAElFTkSuQmCC');
    background-repeat: repeat;
    opacity: 0.05;
    pointer-events: none;
}

/* Desktop Icons */
.icon-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.desktop-icon {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 80px;
    cursor: pointer;
    padding: 5px;
}

.desktop-icon:hover {
    background-color: rgba(157, 50, 250, 0.3);
}

.desktop-icon.active {
    background-color: rgba(157, 50, 250, 0.4);
}

.desktop-icon img {
    width: 32px;
    height: 32px;
    margin-bottom: 5px;
}

.desktop-icon span {
    text-align: center;
    font-size: 0.8rem;
    color: white;
    text-shadow: 
        1px 1px 0 var(--black),
        -1px -1px 0 var(--black),
        1px -1px 0 var(--black),
        -1px 1px 0 var(--black),
        0 0 8px var(--pink);
}

/* Windows 95 Style Form Elements */
.win95-input, .win95-textarea {
    width: 100%;
    padding: 5px;
    background-color: rgba(0, 0, 0, 0.2);
    border: 2px inset var(--window-border);
    color: var(--text-color);
    font-size: 0.9rem;
    transition: all 0.2s ease;
}

.win95-input:focus, .win95-textarea:focus {
    background-color: rgba(0, 0, 0, 0.3);
    box-shadow: 0 0 5px rgba(255, 215, 0, 0.5);
    outline: none;
}

.win95-textarea {
    min-height: 100px;
    resize: vertical;
}

.win95-button {
    padding: 5px 15px;
    background-color: var(--window-color);
    border: 2px outset white;
    color: #000;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    overflow: hidden;
}

.win95-button::before {
    content: "";
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.2),
        transparent
    );
    transition: all 0.5s ease;
}

.win95-button:hover::before {
    left: 100%;
}

.win95-button:hover {
    box-shadow: 0 0 5px rgba(147, 50, 204, 0.5);
}

.win95-button:active {
    border: 2px inset var(--window-border);
    transform: translateY(1px);
} 