/* Kiosk Base Reset */
* {
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    user-select: none; /* Prevent accidental text highlighting */
}

body, html {
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    background-color: #f4f7f6;
    overflow: hidden; /* Prevent edge-scrolling the viewport */
}

/* Main Interface */
#main-view {
    display: flex;
    flex-direction: column;
    height: 100vh;
    padding: 20px; /* Slightly reduced padding to maximize width */
}

#search-bar {
    font-size: 24px;
    padding: 20px;
    border: 2px solid #ccc;
    border-radius: 8px;
    margin-bottom: 20px;
    width: 100%;
    text-align: center; /* Centers the placeholder text for a balanced look */
}

#directory-list {
    flex-grow: 1;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding-bottom: 20px; /* Space at the bottom of the scroll */
}

/* Directory Items - Portrait Optimized (Stacked) */
.directory-item {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 25px;
    display: flex;
    flex-direction: column; /* Stack text and button vertically */
    align-items: center; /* Center everything horizontally */
    text-align: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.business-info {
    margin-bottom: 20px; /* Space between text and button */
}

.business-info h3 {
    margin: 0 0 10px 0;
    font-size: 32px; /* Slightly larger for portrait readability */
    color: #333;
}

.business-info p {
    margin: 0;
    font-size: 22px;
    color: #666;
}

/* Touch-Optimized Buttons */
.call-btn {
    background-color: #0078D7;
    color: white;
    border: none;
    border-radius: 8px;
    width: 100%; /* Full width for massive touch target */
    font-size: 24px;
    font-weight: bold;
    height: 80px;
    cursor: pointer;
}

.call-btn:active {
    background-color: #005a9e;
}

/* Full-Screen Call Modal */
#call-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.98);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: space-evenly; /* Distributes vertical space perfectly in portrait */
    z-index: 1000;
    padding: 40px 20px;
}

#call-status {
    font-size: 40px;
    color: #333;
    text-align: center;
    margin: 0;
}

/* DTMF Keypad Grid - Phone Dialer Style */
#keypad {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px; /* Increased gap for larger portrait screens */
}

.dtmf-btn {
    width: 110px; /* Larger buttons */
    height: 110px;
    font-size: 42px; /* Larger text */
    background-color: #e0e0e0;
    border: none;
    border-radius: 50%;
    color: #333;
    font-weight: bold;
}

.dtmf-btn:active {
    background-color: #ccc;
}

/* Hang Up Button */
#hangup-btn {
    background-color: #d13438;
    color: white;
    border: none;
    border-radius: 8px;
    width: 80%; /* Takes up majority of width at the bottom */
    max-width: 400px;
    font-size: 28px;
    font-weight: bold;
    height: 90px;
}

#hangup-btn:active {
    background-color: #a80000;
}