.container {
    max-width: 100%;
    margin: 0 auto;
}

.main {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

h2, h3 {
    color: var(--primary-color);
}

.button {
    background-color: var(--primary-color);
    color: white;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1em;
    text-decoration: none;
    transition: background-color 0.3s ease;
    display: inline-block;
    margin-top: 20px;
}

.button:hover {
    background-color: #2980b9;
}

.candidate-input-group,
.image-input-options {
    margin-bottom: 20px;
    padding: 15px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    background: #fdfdfd;
}

.candidate-input-group input,
.candidate-input-group textarea {
    width: calc(100% - 20px);
    padding: 10px;
    margin-top: 5px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
}

.drop-zone {
    width: 100%;
    height: 100px;
    padding: 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    cursor: pointer;
    color: #a3a3a3;
    border: 2px dashed #a3a3a3;
    border-radius: 10px;
    font-size: 1em;
    transition: all 0.2s ease-in-out;
}

.drop-zone:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.drop-zone--over {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: scale(1.05);
}

.drop-zone__prompt {
    font-weight: 500;
}

.drop-zone__input {
    display: none;
}

.match-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    justify-content: space-around;
    gap: 10px;
    position: relative;
}

.candidate-card {
    width: 100%;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
    align-self: center;
}

.tournament-info {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 1;
    font-size: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    border-radius: 4rem;
}

.match-info {
    margin-bottom: 1rem;
    padding: 10px;
}

.candidate-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.media-container {
    width: 100%;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.media-container .candidate-name {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 10px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    font-weight: bold;
    text-align: center;
}

.media-container img,
.media-container iframe {
    width: 100%;
    max-height: 500px;
    object-fit: contain;
}

.candidate-card p {
    font-size: 1.2em;
    font-weight: bold;
    color: var(--text-color);
    padding: 10px;
    margin: 0;
    text-align: center;
}

.final-winner {
    margin-top: 30px;
}

.final-winner h3 {
    color: var(--secondary-color);
}

.result-list {
    list-style: none;
    padding: 0;
}

.result-list li {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 8px;
    border-left: 5px solid var(--primary-color);
    margin-bottom: 10px;
    text-align: left;
}

.tournament-info h2 {
    font-size: 2rem; /* 크게 */
    font-weight: bold;
    text-align: center;

    /* 이펙트 */
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
    padding: 0.5rem 1rem;
    border-radius: 50px;
    color: white;
}

.tournament-info h3 {
    padding: 5px;
    background-color: rgb(255 255 255 / 90%);
    border-radius: 12px;
    text-align: center;
}

.last-option--modern {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.last-option--modern .l-button a {
    display: inline-block;
    padding: 12px 20px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: bold;
    font-size: 1rem;
    color: white;
    background-color: #6c5ce7; /* A vibrant purple */
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s, box-shadow 0.2s;
}
.last-option--modern .button-restart a {
    background-color: #6c5ce7;
}

.last-option--modern .button-restart a:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    background-color: #5c4cd9;
}

.last-option--modern .button-result a {
    background-color: #e30909;
}

.last-option--modern .button-result a:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    background-color: #d90909;
}

.last-option--modern .button-game a {
    background-color: #0669b2;
}

.last-option--modern .button-game a:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
    background-color: #0669b2;
}

.toast {
    position: absolute;
    top: -30px;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: #ff3535;
    color: white;
    padding: 10px 20px;
    border-radius: 5px;
    z-index: 9999;
    opacity: 0; /* 처음에는 투명하게 만듭니다 */
    transition: opacity 0.5s ease-in-out; /* 부드러운 효과를 위해 트랜지션을 추가합니다 */
    font-weight: bold;
}

/* 알림이 나타날 때 적용할 클래스 */
.toast.show {
    opacity: 1; /* 투명도를 1로 만들어 보이게 합니다 */
}

.share-container {
    position: relative;
}

.share-btn {
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 0.5rem;
    font-size: 1.5rem;
    cursor: pointer;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    transition: background-color 0.3s ease;
    width: 100%;
}

.share-btn:hover {
    background-color: #27ae60; /* Darker green on hover */
}

.share-btn:focus {
    outline: none; /* Remove default focus outline */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.4); /* Slightly stronger shadow on focus */
}

.candidate-card.selected {
    transform: scale(1.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.candidate-card.loser {
    opacity: 0.5;
    transform: scale(0.9);
}

@media (max-width: 768px) {
    .main-container {
        padding: 0px;
    }
    .match-container {
        display: grid;
        grid-template-columns: 1fr 1fr;
        justify-content: space-around;
        gap: 10px;
        position: relative;
    }

    .match-info {
        margin-bottom: 1rem;
        padding: 0px;
    }


    .tournament-info {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        z-index: 1;
        font-size: 20px;
        display: grid;
        grid-template-columns: 1fr;
        align-items: center;
        border-radius: 4rem;
    }

    .media-container img,
    .media-container iframe {
        width: 100%;
        height: 220px;
        object-fit: contain;
    }


    .tournament-info h2 {
        font-size: 1rem;
    }
}