/* Genel Stiller */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

:root {
    --primary-color: #5D6E3E;  /* Haki yeşil */
    --secondary-color: #D4A86A; /* Altın kahve */
    --accent-color: #8A9A5B; /* Açık haki yeşil */
    --light-color: #F5F5F0; /* Açık bej */
    --dark-color: #3C4930; /* Koyu haki */
    --text-color: #ffffff;
    --background-color: #425201; /* Yeni koyu haki */
    --success-color: #27AE60; /* Yeşil */
    --error-color: #E74C3C; /* Kırmızı */
    --modal-background: rgba(0, 0, 0, 0.7);
    --button-hover: #6d8048;
}

body {
    background-color: var(--background-color);
    color: var(--text-color);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    flex: 1;
}

/* Logo alanı */
.logo-container {
    text-align: center;
    margin-bottom: 20px;
    padding: 20px;
}

.logo-container img {
    max-width: 200px;
    width: 100%;
    height: auto;
    object-fit: contain;
}

header {
    text-align: center;
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.5em;
    font-weight: 800;
    color: var(--text-color);
    margin-bottom: 10px;
}

header h2 {
    font-size: 1.8em;
    font-weight: 500;
    color: var(--secondary-color);
    text-transform: uppercase;
    letter-spacing: 2px;
}

main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: start;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.wheel-section {
    position: sticky;
    top: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.wheel-container {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.result-section {
    display: flex;
    flex-direction: column;
    gap: 30px;
    padding: 20px;
}

#wheel {
    text-rendering: geometricPrecision;
    font-weight: 600;
    font-size: 14px;
    position: relative;
    z-index: 1;
}

.wheel-pointer {
    position: absolute;
    right: -40px; /* Sağ tarafa alındı */
    top: 50%; /* Ortala */
    transform: translateY(-50%); /* Dikey ortalama */
    width: 40px;
    height: 40px;
    z-index: 2;
}

/* Üçgen şekli için yeni stil */
.wheel-pointer::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 0;
    height: 0;
    border-top: 20px solid transparent;
    border-bottom: 20px solid transparent;
    border-right: 40px solid var(--secondary-color);
}

/* Daire şekli için yeni stil */
.wheel-pointer::after {
    content: '';
    position: absolute;
    left: 25px; /* Üçgenin ucuna yakın */
    top: 50%;
    transform: translateY(-50%);
    width: 12px;
    height: 12px;
    background-color: var(--secondary-color);
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.controls {
    display: flex;
    justify-content: center;
    margin-top: auto;
}

.btn {
    padding: 15px 30px;
    border: none;
    border-radius: 25px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
}

.btn.primary {
    font-size: 1.2em;
    padding: 20px 40px;
    min-width: 200px;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    border-radius: 30px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.btn.primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.3);
}

.btn.primary:active {
    transform: translateY(1px);
}

.btn.secondary {
    background-color: transparent;
    border: 2px solid var(--secondary-color);
    color: var(--secondary-color);
}

.btn.secondary:hover {
    background-color: var(--secondary-color);
    color: var(--background-color);
}

/* Ayarlar butonu için özel stil */
.settings-icon {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--secondary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 100;
}

.settings-icon:hover {
    transform: rotate(45deg);
    background-color: #c09355;
}

.settings-icon svg {
    width: 24px;
    height: 24px;
    fill: var(--background-color);
}

.result {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.result.show {
    opacity: 1;
    transform: translateX(0);
}

.result.hidden {
    display: none;
}

.result h3 {
    color: var(--secondary-color);
    font-size: 2.2em;
    margin-bottom: 20px;
    text-transform: uppercase;
    letter-spacing: 2px;
}

.result p {
    font-size: 1.8em;
    color: var(--text-color);
    margin-bottom: 0;
    font-weight: 600;
}

/* Modal Stili */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: var(--modal-background);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.modal-content {
    position: relative;
    background-color: var(--background-color);
    margin: 5% auto;
    padding: 30px;
    border-radius: 15px;
    max-width: 600px;
    width: 90%;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    max-height: 90vh;
    overflow-y: auto;
    color: var(--text-color);
}

.close-modal {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: bold;
    color: var(--text-color);
    cursor: pointer;
}

.modal h2 {
    color: var(--secondary-color);
    margin-bottom: 20px;
    font-size: 1.8em;
}

/* Konfeti Animasyonu için CSS */
@keyframes confetti-fall {
    0% {
        transform: translateY(0) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

.confetti {
    position: fixed;
    width: 10px;
    height: 10px;
    top: -10px;
    pointer-events: none;
    animation: confetti-fall linear forwards;
    z-index: 1000;
}

footer {
    text-align: center;
    padding: 20px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9em;
}

/* Responsive Tasarım */
@media (max-width: 1024px) {
    main {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .wheel-section {
        position: relative;
        top: 0;
    }

    .result-section {
        padding: 0;
    }

    .wheel-pointer {
        right: -30px;
    }

    .wheel-pointer::before {
        border-top: 15px solid transparent;
        border-bottom: 15px solid transparent;
        border-right: 30px solid var(--secondary-color);
    }

    .wheel-pointer::after {
        left: 20px;
        width: 10px;
        height: 10px;
    }
}

@media (max-width: 768px) {
    .container {
        padding: 15px;
    }

    header h1 {
        font-size: 2em;
    }

    header h2 {
        font-size: 1.5em;
    }

    .logo-container img {
        max-width: 150px;
    }

    .btn.primary {
        font-size: 1em;
        padding: 15px 30px;
        min-width: 180px;
    }

    .result h3 {
        font-size: 1.8em;
    }

    .result p {
        font-size: 1.5em;
    }

    .settings-icon {
        bottom: 20px;
        right: 20px;
        width: 40px;
        height: 40px;
    }

    .settings-icon svg {
        width: 20px;
        height: 20px;
    }
}

/* Modal içeriği için stiller */
#segments-container {
    margin: 20px 0;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.segment-item {
    background: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 10px;
    transition: all 0.3s ease;
}

.segment-item:hover {
    background: rgba(255, 255, 255, 0.15);
}

.segment-inputs {
    display: flex;
    align-items: center;
    gap: 15px;
}

.segment-inputs input {
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 6px;
    background: rgba(0, 0, 0, 0.2);
    color: var(--text-color);
    font-family: 'Poppins', sans-serif;
}

.segment-inputs input:focus {
    outline: none;
    border-color: var(--secondary-color);
}

.segment-text {
    flex: 2;
    min-width: 150px;
}

.segment-probability {
    width: 80px;
}

.segment-color {
    width: 40px !important;
    height: 40px;
    padding: 2px !important;
    border-radius: 8px !important;
    cursor: pointer;
}

.probability-display {
    color: var(--secondary-color);
    font-size: 0.9em;
    min-width: 60px;
}

.remove-segment {
    background: none;
    border: none;
    color: var(--error-color);
    font-size: 24px;
    cursor: pointer;
    padding: 0 8px;
    opacity: 0.7;
    transition: all 0.3s ease;
}

.remove-segment:hover {
    opacity: 1;
    transform: scale(1.1);
}

#add-segment {
    margin-top: 20px;
    align-self: center;
}

/* Ayarlar menüsü */
.settings-menu {
    position: absolute;
    top: 60px;
    right: 20px;
    background: var(--background-color);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 10px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.settings-menu button {
    width: 100%;
    padding: 10px 15px;
    border: none;
    background: none;
    text-align: left;
    cursor: pointer;
    border-radius: 4px;
    transition: background-color 0.2s;
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
    color: var(--text-color);
}

.settings-menu button:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Mesaj ayarları modalı */
#message-settings {
    max-height: 70vh;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.message-group {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 15px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.message-group h3 {
    margin: 0 0 15px 0;
    color: var(--secondary-color);
    font-size: 1.1em;
}

.message-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.message-item {
    display: flex;
    gap: 10px;
    align-items: flex-start;
}

.message-input {
    flex: 1;
    min-height: 60px;
    padding: 10px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9em;
    resize: vertical;
    background: rgba(0, 0, 0, 0.2);
    color: white;
}

.message-input:focus {
    border-color: var(--secondary-color);
    outline: none;
    box-shadow: 0 0 0 2px rgba(212, 168, 106, 0.2);
}

.delete-message {
    padding: 8px 12px;
    background: #ff6b6b;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8em;
    transition: background-color 0.2s;
}

.delete-message:hover {
    background: #ff5252;
}

.add-message {
    margin-top: 10px;
    padding: 8px 15px;
    background: #8A9A5B;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
    transition: background-color 0.2s;
}

.add-message:hover {
    background: #7A8A4B;
}

/* Modal butonları */
.modal-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
    padding: 15px;
    border-top: 1px solid #eee;
}

.modal-buttons button {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.2s;
}

#save-messages {
    background: #8A9A5B;
    color: white;
}

#save-messages:hover {
    background: #7A8A4B;
}

#reset-messages {
    background: #ff6b6b;
    color: white;
}

#reset-messages:hover {
    background: #ff5252;
}

#close-messages {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-color);
}

#close-messages:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* Ses İzni Modalı */
.permission-modal .modal-content {
    max-width: 400px;
    text-align: center;
}

.permission-modal h2 {
    color: #D4A86A;
    margin-bottom: 1rem;
}

.permission-modal p {
    color: white;
    margin-bottom: 1.5rem;
    line-height: 1.5;
}

.volume-warning {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(212, 168, 106, 0.2);
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1.5rem;
}

.volume-warning svg {
    color: #D4A86A;
    flex-shrink: 0;
}

.volume-warning span {
    color: #D4A86A;
    font-weight: 500;
}

/* Mesaj Stilleri */
.message {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    padding: 1rem 2rem;
    border-radius: 0.5rem;
    color: white;
    font-weight: 500;
    z-index: 2000;
    animation: slideUp 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.message.success {
    background: #4CAF50;
}

.message.error {
    background: #f44336;
}

.message.info {
    background: #2196F3;
}

@keyframes slideUp {
    from {
        transform: translate(-50%, 100%);
        opacity: 0;
    }
    to {
        transform: translate(-50%, 0);
        opacity: 1;
    }
}

/* Mobil için düzenlemeler */
@media (max-width: 480px) {
    .permission-modal .modal-content {
        width: 90%;
        padding: 1.5rem;
    }

    .message {
        width: 90%;
        padding: 1rem;
        text-align: center;
    }
}

.spin-result-modal {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background: 
      linear-gradient(120deg, #5D6E3E 0%, #D4A86A 100%),
      url('data:image/svg+xml;utf8,<svg width="60" height="60" viewBox="0 0 60 60" fill="none" xmlns="http://www.w3.org/2000/svg"><g opacity="0.08"><ellipse cx="30" cy="30" rx="18" ry="18" fill="%23fff"/><path d="M30 18c-6.627 0-12 4.03-12 9s5.373 9 12 9 12-4.03 12-9-5.373-9-12-9zm0 16c-5.523 0-10-3.134-10-7s4.477-7 10-7 10 3.134 10 7-4.477 7-10 7z" fill="%235D6E3E"/></g></svg>');
    background-size: cover, 120px;
    background-repeat: no-repeat, repeat;
    background-blend-mode: lighten;
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.3s;
    overflow: hidden;
}
.spin-result-modal.hidden {
    display: none;
}
.spin-result-modal-content {
    background: rgba(93, 110, 62, 0.92); /* haki yeşil, opak */
    border-radius: 32px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.18), 0 2px 8px rgba(76,175,80,0.08);
    padding: 56px 32px 40px 32px;
    min-width: 320px;
    max-width: 95vw;
    text-align: center;
    position: relative;
    animation: popInCelebration 0.7s cubic-bezier(.68,-0.55,.27,1.55);
    overflow: visible;
}
@keyframes popInCelebration {
    0% { transform: scale(0.6) rotate(-8deg); opacity: 0; }
    70% { transform: scale(1.08) rotate(2deg); opacity: 1; }
    100% { transform: scale(1) rotate(0deg); opacity: 1; }
}
.spin-result-main {
    font-size: 2.8rem;
    font-weight: 900;
    background: linear-gradient(90deg, #D4A86A 0%, #fffbe6 100%);
    color: #5D6E3E;
    padding: 22px 0 22px 0;
    border-radius: 22px;
    margin-bottom: 18px;
    box-shadow: 0 4px 24px 0 #d4a86a40, 0 0 0 8px #fffbe622;
    letter-spacing: 2px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    text-shadow: 0 2px 12px #fffbe677, 0 0 8px #d4a86acc;
    border: 2px solid #fffbe6;
    animation: glowResult 1.2s infinite alternate;
}
@keyframes glowResult {
    0% { box-shadow: 0 4px 24px 0 #d4a86a40, 0 0 0 8px #fffbe622; }
    100% { box-shadow: 0 8px 32px 0 #d4a86a77, 0 0 0 16px #fffbe633; }
}
.spin-result-main::before {
    content: '\1F389'; /* confetti emoji */
    font-size: 2.5rem;
    margin-right: 10px;
    filter: drop-shadow(0 2px 2px #fffbe633);
    animation: popEmoji 1.2s infinite alternate;
}
@keyframes popEmoji {
    0% { transform: scale(1) rotate(-8deg); }
    100% { transform: scale(1.15) rotate(8deg); }
}
.spin-result-message {
    font-size: 1.18rem;
    color: #fffbe6;
    background: rgba(212,168,106,0.18);
    border-radius: 14px;
    padding: 16px 12px;
    margin-bottom: 32px;
    box-shadow: 0 1px 8px rgba(212,168,106,0.10);
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: center;
    border: 1.5px solid #fffbe644;
}
.spin-result-message::before {
    content: '\1F31F'; /* sparkling star emoji */
    font-size: 1.3rem;
    margin-right: 6px;
    opacity: 0.8;
}
#close-spin-modal {
    margin-top: 8px;
    padding: 18px 48px;
    font-size: 1.25rem;
    border-radius: 14px;
    background: linear-gradient(90deg, #D4A86A 0%, #5D6E3E 100%);
    color: #fff;
    font-weight: 800;
    border: none;
    box-shadow: 0 2px 12px rgba(93,110,62,0.13);
    cursor: pointer;
    transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
    letter-spacing: 1px;
    text-shadow: 0 1px 8px #d4a86a77;
    animation: popButton 1.2s infinite alternate;
}
@keyframes popButton {
    0% { transform: scale(1); box-shadow: 0 2px 12px rgba(93,110,62,0.13); }
    100% { transform: scale(1.07); box-shadow: 0 6px 24px #5d6e3e33; }
}
#close-spin-modal:hover {
    background: linear-gradient(90deg, #5D6E3E 0%, #D4A86A 100%);
    transform: translateY(-2px) scale(1.08);
}
@media (max-width: 600px) {
    .spin-result-modal-content {
        padding: 18px 4px 16px 4px;
        min-width: 0;
    }
    .spin-result-main {
        font-size: 1.5rem;
        padding: 10px 0;
    }
    .spin-result-message {
        font-size: 1rem;
        padding: 10px 4px;
    }
    #close-spin-modal {
        font-size: 1.05rem;
        padding: 12px 0;
        width: 100%;
    }
} 