@import url('https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&family=Comic+Neue:wght@400;700&display=swap');

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

body {
    font-family: 'Comic Neue', cursive;
    background-color: #0c0c2a;
    background-image: url('images/bg.gif');
    color: #e0e0ff;
    line-height: 1.6;
    text-align: center;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Password screen styles */
.password-container {
    width: 100%;
    max-width: 500px;
    animation: cosmic-pulse 3s infinite;
}

@keyframes cosmic-pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); }
    100% { transform: scale(1); }
}

.password-box {
    background-color: rgba(20, 20, 50, 0.85);
    border: 5px solid #6e3dc8;
    border-radius: 15px;
    padding: 30px 20px;
    box-shadow: 0 0 25px rgba(100, 100, 255, 0.7);
    position: relative;
    overflow: hidden;
}

.password-box:before, .password-box:after {
    content: "★";
    font-size: 24px;
    color: #9966ff;
    position: absolute;
    top: 10px;
}

.password-box:before {
    left: 15px;
}

.password-box:after {
    right: 15px;
}

.password-input {
    margin: 25px 0 15px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    align-items: center;
}

#password-field {
    width: 80%;
    padding: 12px;
    border: 2px solid #6633cc;
    border-radius: 5px;
    background-color: rgba(10, 10, 30, 0.8);
    color: #e0e0ff;
    font-family: 'Orbitron', monospace;
    font-size: 1rem;
    text-align: center;
    letter-spacing: 2px;
}

#password-field:focus {
    outline: none;
    border-color: #9933ff;
    box-shadow: 0 0 15px rgba(153, 51, 255, 0.5);
}

#submit-password {
    padding: 8px 25px;
    background: linear-gradient(to right, #6633cc, #9900ff);
    border: 2px solid #6633cc;
    border-radius: 5px;
    color: #ffffff;
    font-family: 'Orbitron', sans-serif;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    letter-spacing: 1px;
    box-shadow: 0 0 10px rgba(153, 51, 255, 0.3);
}

#submit-password:hover {
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(153, 51, 255, 0.6);
}

.password-hint {
    margin-top: 20px;
    font-size: 0.9rem;
    color: #9966ff;
    font-style: italic;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: rgba(20, 20, 50, 0.85);
    border: 5px solid #6e3dc8;
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 0 15px rgba(100, 100, 255, 0.5);
    position: relative;
    width: 100%;
}

/* Cosmic decorations for container */
.container:before, .container:after {
    content: "★";
    font-size: 24px;
    color: #9966ff;
    position: absolute;
    top: -5px;
}

.container:before {
    left: 10px;
}

.container:after {
    right: 10px;
}

.header {
    margin-bottom: 30px;
    animation: cosmic-glow 5s infinite;
}

@keyframes cosmic-glow {
    0% { text-shadow: 0 0 5px #5d00ff; }
    50% { text-shadow: 0 0 20px #b300ff; }
    100% { text-shadow: 0 0 5px #5d00ff; }
}

h1 {
    font-family: 'Orbitron', sans-serif;
    font-size: 3rem;
    margin-bottom: 10px;
    text-shadow: 0 0 10px #9933ff;
    position: relative;
    display: inline-block;
    letter-spacing: 2px;
    background: linear-gradient(to right, #9900ff, #00ccff, #9900ff);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

h2 {
    font-family: 'Orbitron', sans-serif;
    font-size: 1.5rem;
    margin-bottom: 15px;
    color: #00ccff;
    text-shadow: 0 0 5px #00ccff;
    letter-spacing: 1px;
}

h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: #9966ff;
}

.under-construction {
    margin: 10px 0;
}

.cipher-section {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 30px;
}

.input-box {
    background-color: rgba(30, 30, 60, 0.7);
    border: 2px solid #6633cc;
    padding: 10px;
    border-radius: 8px;
    position: relative;
}

textarea {
    width: 100%;
    height: 120px;
    padding: 10px;
    border: 2px solid #6633cc;
    border-radius: 5px;
    font-family: 'Orbitron', monospace;
    font-size: 1rem;
    resize: none;
    color: #e0e0ff;
    background-color: rgba(10, 10, 30, 0.8);
    margin-bottom: 10px;
}

/* Copy Button Styles */
.copy-button {
    padding: 5px 12px;
    background: linear-gradient(to right, #6633cc, #8855dd);
    border: 2px solid #6633cc;
    border-radius: 5px;
    color: #ffffff;
    font-family: 'Orbitron', sans-serif;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    display: inline-flex;
    align-items: center;
    box-shadow: 0 0 8px rgba(153, 51, 255, 0.3);
    margin: 5px 0;
    width: 100%;
    text-align: center;
    display: block;
}

.copy-button:hover {
    transform: scale(1.05);
    box-shadow: 0 0 12px rgba(153, 51, 255, 0.6);
    background: linear-gradient(to right, #7744dd, #9966ee);
}

.copy-button:active {
    transform: scale(0.95);
}

.copy-icon {
    font-size: 1.1rem;
}

.copy-success {
    animation: flash-success 1s;
}

@keyframes flash-success {
    0%, 100% { background: linear-gradient(to right, #6633cc, #8855dd); }
    50% { background: linear-gradient(to right, #44cc44, #66dd66); }
}

.arrows {
    display: flex;
    justify-content: space-between;
    font-size: 1.8rem;
    font-weight: bold;
    color: #00ccff;
    padding: 0 20px;
    margin: 0 30%;
}

.arrows div {
    position: relative;
}

.arrows div:before, .arrows div:after {
    content: "✧";
    font-size: 1rem;
    position: absolute;
    color: #9933ff;
}

.arrows div:before {
    left: -15px;
}

.arrows div:after {
    right: -15px;
}

.cipher-key {
    background-color: rgba(0, 10, 40, 0.7);
    border: 3px solid #6633cc;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 0 10px rgba(153, 0, 255, 0.5) inset;
}

/* Add star accents to the cipher key box */
.cipher-key:before {
    content: "✧";
    position: absolute;
    top: 5px;
    left: 5px;
    font-size: 1rem;
    color: #9966ff;
    opacity: 0.7;
}

.cipher-key:after {
    content: "✧";
    position: absolute;
    bottom: 5px;
    right: 5px;
    font-size: 1rem;
    color: #9966ff;
    opacity: 0.7;
}

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

.key-row {
    display: flex;
    gap: 10px;
    justify-content: center;
    align-items: center;
}

.key-label {
    font-weight: bold;
    color: #00ccff;
    flex: 0 0 80px;
    text-align: right;
}

.key-value {
    font-family: monospace;
    letter-spacing: 2px;
    background-color: rgba(0, 10, 30, 0.8);
    padding: 5px;
    border: 1px solid #6633cc;
    border-radius: 3px;
    color: #e0e0ff;
}

.footer {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 3px solid #6633cc;
    font-size: 0.9rem;
    position: relative;
}

/* Add cosmic border to footer */
.footer:before {
    content: "★ ✧ ★ ✧ ★ ✧ ★ ✧ ★";
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 1rem;
    color: #9966ff;
    background-color: rgba(20, 20, 50, 0.85);
    padding: 0 10px;
}

.counter {
    margin: 15px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.guestbook {
    margin: 15px 0;
}

.guestbook a {
    display: inline-block;
    padding: 5px 10px;
    background-color: rgba(100, 50, 180, 0.5);
    border: 2px outset #9933ff;
    color: #00ccff;
    text-decoration: none;
    font-weight: bold;
    position: relative;
}

.guestbook a:hover {
    background-color: rgba(120, 70, 200, 0.5);
    border-style: inset;
    box-shadow: 0 0 10px #9933ff;
}

/* Add star elements to the guestbook link */
.guestbook a:before, .guestbook a:after {
    content: "★";
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #9933ff;
}

.guestbook a:before {
    left: -15px;
}

.guestbook a:after {
    right: -15px;
}

/* Floating star animation */
@keyframes float {
    0% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(10deg); }
    100% { transform: translateY(0px) rotate(0deg); }
}

/* Twinkling stars effect */
@keyframes twinkle {
    0% { opacity: 0.3; }
    50% { opacity: 1; }
    100% { opacity: 0.3; }
}

/* Media queries for better responsiveness */
@media (min-width: 768px) {
    .cipher-section {
        flex-direction: row;
    }
    
    .input-box {
        flex: 1;
    }
    
    .arrows {
        flex-direction: column;
        margin: 0;
        justify-content: center;
    }
    
    .arrows div:nth-child(1) {
        transform: rotate(-90deg);
    }
    
    .arrows div:nth-child(2) {
        transform: rotate(-90deg);
    }
}