* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: url('../Assets/Images/residence-background-photo.jpg') center/cover no-repeat fixed;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    position: relative;
}

body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 0;
}

.admin-nav {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 1000;
}

.btn-admin {
    padding: 10px 20px;
    background: #5DBDBD;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    transition: all 0.3s;
    display: inline-block;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.btn-admin:hover {
    background: #4DADAD;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.modal {
    background: white;
    border-radius: 8px;
    max-width: 480px;
    width: 100%;
    max-height: 95vh;
    overflow-y: auto;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 1;
    padding: 30px 40px 35px;
}

.modal h2 {
    font-size: 22px;
    color: #333;
    margin-bottom: 6px;
    font-weight: 600;
}

.modal p {
    color: #666;
    margin-bottom: 18px;
    font-size: 14px;
    line-height: 1.5;
}

.form-group {
    margin-bottom: 12px;
}

.form-group input {
    width: 100%;
    padding: 9px 14px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: #5DBDBD;
}

.form-group input.error {
    border-color: #f44336;
}

.form-group small {
    display: block;
    margin-top: 4px;
    color: #999;
    font-size: 11px;
    font-style: italic;
}

.form-group small.error {
    color: #f44336;
}

.address-dropdown {
    position: relative;
    margin-bottom: 12px;
}

.address-suggestions {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 10;
    display: none;
}

.address-suggestions.show {
    display: block;
}

.address-suggestion {
    padding: 12px 15px;
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.2s;
}

.address-suggestion:hover,
.address-suggestion.selected {
    background: #5DBDBD;
    color: white;
}

.address-suggestion:last-child {
    border-bottom: none;
}

.btn {
    padding: 10px 25px;
    border: none;
    border-radius: 4px;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s;
    font-weight: 500;
    width: 100%;
}

.btn-primary {
    background: #5DBDBD;
    color: white;
    text-transform: none;
    letter-spacing: 0.5px;
}

.btn-primary:hover {
    background: #4DADAD;
}

.btn-primary:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
    gap: 10px;
}

.btn-cancel {
    background: transparent;
    color: #5DBDBD;
    padding: 9px 22px;
    border: none;
    font-size: 14px;
    cursor: pointer;
    font-weight: 500;
    flex: 1;
}

.btn-cancel:hover {
    text-decoration: underline;
}

.btn-continue {
    background: #5DBDBD;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 9px 22px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    font-weight: 500;
    flex: 1;
}

.btn-continue:hover {
    background: #4DADAD;
}

.btn-continue:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.terms {
    font-size: 11.5px;
    color: #666;
    margin-top: 12px;
    line-height: 1.4;
}

.terms a {
    color: #5DBDBD;
    text-decoration: none;
}

.terms a:hover {
    text-decoration: underline;
}

.consent-text {
    font-size: 10.5px;
    color: #555;
    margin-top: 12px;
    line-height: 1.55;
    max-height: none;
    overflow-y: visible;
    padding: 12px 14px;
    background: #f9f9f9;
    border-radius: 4px;
}

.consent-text p {
    margin-bottom: 10px;
    font-size: 10.5px;
}

.consent-text p:last-child {
    margin-bottom: 0;
}

.form-section {
    display: none;
}

.form-section.active {
    display: block;
}

.chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 2px solid #5DBDBD;
}

.timer {
    background: #ff6b6b;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
}

.timer.warning {
    background: #ff9800;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

.chat-messages {
    max-height: 350px;
    overflow-y: auto;
    margin-bottom: 15px;
    padding: 15px;
    background: #f9f9f9;
    border-radius: 4px;
}

.message {
    margin-bottom: 15px;
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.message.bot {
    text-align: left;
}

.message.user {
    text-align: right;
}

.message-bubble {
    display: inline-block;
    padding: 10px 15px;
    border-radius: 15px;
    max-width: 80%;
    word-wrap: break-word;
}

.message.bot .message-bubble {
    background: #5DBDBD;
    color: white;
    border-bottom-left-radius: 4px;
}

.message.user .message-bubble {
    background: #e0e0e0;
    color: #333;
    border-bottom-right-radius: 4px;
}

.chat-input-container {
    display: flex;
    gap: 10px;
}

.chat-input-container input {
    flex: 1;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 15px;
}

.chat-input-container button {
    padding: 12px 25px;
    background: #5DBDBD;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: 500;
}

.chat-input-container button:hover {
    background: #4DADAD;
}

.chat-input-container button:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.loading {
    display: inline-block;
    padding: 10px 15px;
}

.loading::after {
    content: '...';
    animation: dots 1.5s infinite;
}

@keyframes dots {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

.end-chat-btn {
    width: 100%;
    padding: 12px;
    background: #f44336;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    margin-top: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.end-chat-btn:hover {
    background: #da190b;
}

.chat-ended-message {
    background: #fff3cd;
    color: #856404;
    padding: 15px;
    border-radius: 4px;
    margin-bottom: 15px;
    text-align: center;
    font-weight: 500;
}

.handoff-message {
    background: white;
    color: #6d6262;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 15px;
    text-align: center;
    font-size: 16px;
    line-height: 1.6;
    font-weight: 500;
}

.branding-container {
    text-align: center;
}

.branding-container h2 {
    font-size: 28px;
    color: #333;
    margin-bottom: 30px;
    text-decoration: underline;
}

.agent-card {
    background: white;
    padding: 30px;
    border-radius: 8px;
    max-width: 500px;
    margin: 0 auto;
}

.agent-photo {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    margin: 0 auto 20px;
    object-fit: cover;
    background: #f0f0f0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 64px;
    color: #ccc;
}

.agent-name {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

.agent-company {
    font-size: 16px;
    color: #666;
    margin-bottom: 20px;
}

.agent-description {
    font-size: 15px;
    color: #555;
    line-height: 1.6;
    margin-top: 20px;
}