html, body {
    margin: 0;
    padding: 0;
    width: 400px;
    height: 400px;
    box-sizing: border-box;
    overflow: hidden;
    background-color: #121212;
    color: #ffffff;
    font-family: Arial, sans-serif;
}

.container {
    display: flex;
    flex-direction: column;
    width: 400px;
    height: 400px;
    background-color: #1e1e1e;
    border: 1px solid #333333;
    border-radius: 8px;
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.8);
    overflow-y: auto;
}

.tabs {
    display: flex;
    justify-content: space-evenly;
    background-color: #2c2c2c;
    border-bottom: 2px solid #444444;
    padding: 8px 0;
}

.tab-button {
    flex: 1;
    padding: 10px;
    text-align: center;
    color: #cccccc;
    background-color: #2c2c2c;
    border: none;
    outline: none;
    cursor: pointer;
    transition: background-color 0.2s, color 0.2s;
    font-weight: bold;
}

.tab-button:hover {
    background-color: #444444;
    color: #ffffff;
}

.tab-button.active {
    background-color: #1e88e5;
    color: #ffffff;
}

.tab-content {
    flex: 1;
    padding: 16px;
    display: none;
    overflow-y: auto;
}

.tab-content.active {
    display: block;
}

h2 {
    font-size: 1.5em;
    margin-bottom: 12px;
    color: #ffffff;
}

.streams-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.stream-item {
    padding: 10px;
    margin: 8px 0;
    background-color: #333333;
    color: #ffffff;
    border-radius: 6px;
    transition: background-color 0.2s;
}

.stream-item:hover {
    background-color: #444444;
}

.settings-item {
    margin: 12px 0;
    padding: 8px 12px;
    background-color: #2c2c2c;
    color: #ffffff;
    border-radius: 6px;
    display: flex;
    align-items: center;
}

.settings-item label {
    margin-left: 8px;
    font-size: 1em;
    color: #cccccc;
}

h1 {
    font-size: 24px;
    margin-bottom: 20px;
    text-align: center;
    color: #0096c7;
    font-weight: 600;
}

#m3u8-list {
    list-style: none;
    padding: 0;
    margin: 0;
    max-height: 350px;
    overflow-y: auto;
}

li {
    background: linear-gradient(45deg, #4a90e2, #6fa3e3);
    margin: 10px 0;
    padding: 12px;
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.2);
    transition: transform 0.3s ease, background 0.3s ease;
}

li:hover {
    transform: translateY(-4px);
    background: linear-gradient(45deg, #6fa3e3, #4a90e2);
}

span {
    font-size: 14px;
    font-weight: 500;
    color: #ffffff;
    word-wrap: break-word;
    max-width: 220px;
    overflow: hidden;
    text-overflow: ellipsis;
}

.download-btn {
    background-color: #0096c7;
    color: white;
    border: none;
    padding: 8px 15px;
    border-radius: 25px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.download-btn:hover {
    background-color: #08b62d;
}

p {
    color: #bbb;
    text-align: center;
    font-size: 14px;
}

.port-setting {
    margin-top: 20px;
}

.port-setting label {
    font-size: 14px;
    display: block;
    margin-bottom: 5px;
}

.port-setting input[type="number"] {
    width: 350px;
    padding: 8px;
    border: 1px solid #ccc;
    border-radius: 4px;
    font-size: 14px;
}

.port-setting button {
    width: 368px;
    padding: 8px;
    font-size: 14px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    margin-top: 10px;
}

.port-setting button:hover {
    background-color: #0056b3;
}



.toggle-setting {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
}

.switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 20px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .2s;
    border-radius: 34px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: .2s;
    border-radius: 50%;
}

.switch input:checked + .slider {
    background-color: #2196F3;
}

.switch input:checked + .slider:before {
    transform: translateX(20px);
}

.label-text {
    font-size: 14px;
}

.tooltip-wrapper {
    position: relative;
    display: inline-block;
}

.tooltip-wrapper {
    position: relative;
    display: inline-block;
}

.tooltip-text {
    visibility: hidden;
    opacity: 0;
    width: 220px;
    background-color: #333;
    color: #fff;
    text-align: left;
    border-radius: 5px;
    padding: 8px;
    position: absolute;
    top: 125%;
    left: 50%;
    transform: translateX(-10%);
    z-index: 10;
    transition: opacity 0.2s;
    font-size: 12px;
    white-space: normal;
    pointer-events: none;
}

.tooltip-wrapper:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

