* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    overflow: hidden;
    font-family: Arial, sans-serif;
    background: #343541;
}

.layout-container {
    width: 100vw;
    height: 100vh;
    position: relative;
}

.chat-column {
    position: fixed;
    top: 80px;
    bottom: 30px;
    right: 30px;
    width: 300px;
    background: rgba(52, 53, 65, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    z-index: 2;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
}

.scene-column {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
}

canvas {
    display: block;
    width: 100%;
    height: 100%;
}

.chat-container {
    flex: 1;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.chat-history {
    flex: 1;
    overflow-y: auto;
    padding: 15px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

@keyframes messageAppear {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.chat-message {
    max-width: 85%;
    padding: 8px 12px;
    border-radius: 8px;
    word-wrap: break-word;
    line-height: 1.4;
    font-size: 14px;
    animation: messageAppear 0.3s ease-out forwards;
    opacity: 0;
}

.bot-message {
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.user-message {
    align-self: flex-end;
    background: #2b2c2f;
    color: #fff;
}

.input-container {
    padding: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.input-field {
    width: 100%;
    min-height: 40px;
    max-height: 120px;
    padding: 10px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-size: 14px;
    resize: none;
    outline: none;
}

.input-field::placeholder {
    color: rgba(255, 255, 255, 0.5);
}

.about-link {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 5;
    color: white;
    text-decoration: none;
    padding: 8px 15px;
    background: rgba(52, 53, 65, 0.9);
    border-radius: 6px;
    font-size: 14px;
    transition: background-color 0.3s;
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

.about-link:hover {
    background: #444654;
}

.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10;
    display: none;
    justify-content: center;
    align-items: center;
}

.popup-content {
    background: #343541;
    padding: 25px;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    color: white;
    position: relative;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.3);
}

.popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    color: #8E8EA0;
    cursor: pointer;
    font-size: 20px;
    line-height: 1;
}

.popup-close:hover {
    color: white;
}

.popup-title {
    font-size: 20px;
    margin-bottom: 15px;
    color: white;
}

.popup-text {
    line-height: 1.5;
    color: #D1D1D1;
}

.popup-text a {
    color: #9BA1FF;
    text-decoration: none;
}

.popup-text a:hover {
    text-decoration: underline;
}

/* Custom scrollbar for chat history */
.chat-history::-webkit-scrollbar {
    width: 6px;
}

.chat-history::-webkit-scrollbar-track {
    background: transparent;
}

.chat-history::-webkit-scrollbar-thumb {
    background: #565869;
    border-radius: 3px;
}

.chat-history::-webkit-scrollbar-thumb:hover {
    background: #787A91;
}

/* Boat Controls Panel */
.boat-controls {
    position: fixed;
    bottom: 30px;
    left: 30px;
    display: flex;
    gap: 15px;
    z-index: 2;
}

.control-item {
    background: rgba(32, 33, 35, 0.95);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    padding: 8px;
    color: white;
    font-family: 'Courier New', monospace;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.2);
    width: 60px;
    height: 60px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* Digital Clock */
.game-clock {
    font-size: 14px;
    text-align: center;
    letter-spacing: 1px;
    background: #1a1a1a;
    border: 2px solid #333;
    white-space: nowrap;
}

/* Speed Gauge */
.speed-gauge {
    background: #1a1a1a;
    border: 2px solid #333;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.gauge-label {
    display: none;
}

.gauge-value {
    font-size: 18px;
    margin: 0;
}

.gauge-unit {
    font-size: 8px;
    color: #888;
    margin-top: 2px;
    font-family: Arial, sans-serif;
    text-transform: lowercase;
}

/* Compass */
.compass {
    background: #1a1a1a;
    border: 2px solid #333;
    padding: 5px;
}

.compass-rose {
    width: 40px;
    height: 40px;
    border: 1px solid white;
    border-radius: 50%;
    position: relative;
}

.compass-arrow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 1px;
    height: 30px;
    background: white;
    transform-origin: center center;
    transform: translate(-50%, -50%) rotate(0deg);
}

.compass-arrow::after {
    content: '';
    position: absolute;
    top: -5px;
    left: -4px;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-bottom: 8px solid white;
}

.compass-value {
    display: none;
}

@keyframes blink {
    0% { opacity: 0.2; }
    20% { opacity: 1; }
    100% { opacity: 0.2; }
}

.thinking {
    display: flex;
    gap: 4px;
    padding: 8px 12px;
    align-self: flex-start;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    margin-bottom: 8px;
}

.thinking span {
    width: 6px;
    height: 6px;
    background: #fff;
    border-radius: 50%;
    animation: blink 1.4s infinite linear;
}

.thinking span:nth-child(2) {
    animation-delay: 0.2s;
}

.thinking span:nth-child(3) {
    animation-delay: 0.4s;
}

#boat-tracking-label {
    transform: translate(-50%, -150%); /* Center horizontally and position above the point */
    pointer-events: none;
    user-select: none;
    white-space: nowrap;
} 