/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    line-height: 1.6;
}

/* Card Container */
.card {
    background: rgba(231, 76, 60, 0.95);
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3);
    color: white;
    max-width: 900px; /* Reduced max-width for better readability is at 900 */
    width: 100%;
    position: relative;
    overflow: hidden; /* Contains floats */
    animation: slideUp 0.6s ease-out;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 20px;
    pointer-events: none;
}

/* Typography */
.title {
    font-size: 2.2rem;
    font-weight: bold;
    text-align: center;
    margin-bottom: 30px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    line-height: 1.2;
}

p {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
}

a {
    color: #ffd700; /* Gold color for links */
    text-decoration: none;
    border-bottom: 1px dotted #ffd700;
    transition: color 0.3s;
}

a:hover {
    color: #fff;
    border-bottom-style: solid;
}

.footnote {
    font-size: 0.9rem;
    font-style: italic;
    opacity: 0.9;
}

/* Image Floats */
.img-float-left {
    float: left;
    margin: 5px 20px 10px 0;
    width: 150px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    border: 3px solid rgba(255,255,255,0.2);
}

.img-float-right {
    float: right;
    display: block; /* Ensure anchor behaves as block when floated */
    margin: 5px 0 10px 20px;
    width: 150px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    border: 3px solid rgba(255,255,255,0.2);
    transition: transform 0.3s ease;
    overflow: hidden; /* Clips image to border radius */
}

.img-float-right img {
    display: block;
    width: 100%;
    height: auto;
}

.img-float-right:hover {
    transform: scale(1.05);
}

/* Clearfix for main content */
.main-content::after {
    content: "";
    display: table;
    clear: both;
}

/* Form Styles */
.styled-form {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.2);
}

.form-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 25px;
}

.radio-option {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    padding: 10px;
    border-radius: 8px;
    transition: background 0.3s;
}

.radio-option:hover {
    background: rgba(255,255,255,0.1);
}

/* Custom Radio Button */
.radio-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.radio-custom {
    position: relative;
    height: 24px;
    width: 24px;
    background-color: rgba(255,255,255,0.2);
    border-radius: 50%;
    margin-right: 15px;
    flex-shrink: 0;
    border: 2px solid rgba(255,255,255,0.5);
    transition: all 0.3s ease;
}

.radio-option input:checked ~ .radio-custom {
    background-color: #fff;
    border-color: #fff;
    transform: scale(1.1);
}

.radio-custom::after {
    content: "";
    position: absolute;
    display: none;
    top: 6px;
    left: 6px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #e74c3c;
}

.radio-option input:checked ~ .radio-custom::after {
    display: block;
}

.radio-label {
    font-size: 1.1rem;
    line-height: 1.4;
}

.form-input {
    margin-bottom: 25px;
}

.form-input label {
    display: block;
    margin-bottom: 10px;
    font-weight: bold;
    font-size: 1.1rem;
}

textarea {
    width: 100%;
    padding: 15px;
    border-radius: 10px;
    border: 2px solid rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.1);
    color: white;
    font-size: 1rem;
    font-family: inherit;
    resize: vertical;
    transition: all 0.3s ease;
}

textarea:focus {
    outline: none;
    background: rgba(255,255,255,0.2);
    border-color: white;
    box-shadow: 0 0 10px rgba(255,255,255,0.1);
}

textarea::placeholder {
    color: rgba(255,255,255,0.6);
}

.form-submit {
    text-align: center;
}

input[type="submit"] {
    background: white;
    color: #e74c3c;
    border: none;
    padding: 15px 40px;
    font-size: 1.2rem;
    font-weight: bold;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    text-transform: uppercase;
    letter-spacing: 1px;
}

input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.3);
    background: #f1f1f1;
}

input[type="submit"]:active {
    transform: translateY(1px);
}

/* Animations */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile Optimizations */
@media (max-width: 767px) {
    .card {
        padding: 25px;
        margin: 10px;
        width: auto;
    }

    .title {
        font-size: 1.8rem;
    }

    /* Stack images on mobile or keep floated but smaller */
    .img-float-left, .img-float-right {
        float: none;
        display: block;
        margin: 0 auto 20px;
        width: 180px; /* Slightly larger when centered */
        max-width: 100%;
    }

    .main-content {
        text-align: left; /* Keep text left aligned usually better for reading */
    }

    .img-float-right {
        margin: 20px auto;
    }

    .radio-label {
        font-size: 1rem;
    }

    input[type="submit"] {
        width: 100%;
    }
}
