/* iOS-Style UI Components */

/* iOS-Style Top Navigation Bar */
.top-nav {
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: calc(12px + env(safe-area-inset-top, 0)) 16px 12px;
    position: sticky;
    top: 0;
    z-index: 100;
    border-bottom: 1px solid var(--ios-medium-gray);
}

.top-nav .back-button {
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    color: var(--ios-kdd);
    font-size: 18px;
}

.top-nav .page-title {
    font-size: 17px;
    font-weight: 600;
    color: var(--ios-text-primary);
}

.top-nav .empty-space {
    width: 30px;
}

/* iOS-Style Card Detail View */
.company-detail-card {
    background-color: var(--ios-card);
    border-radius: var(--ios-border-radius);
    margin: 16px;
    padding: 20px;
    box-shadow: var(--ios-shadow);
}

.company-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--ios-text-primary);
}

.rating-container {
    display: flex;
    justify-content: space-between;
    margin-bottom: 20px;
}

.rating-item {
    text-align: center;
    flex: 1;
}

.rating-label {
    font-size: 14px;
    color: var(--ios-text-tertiary);
    margin-bottom: 4px;
}

.rating-value {
    font-size: 22px;
    font-weight: 600;
    color: var(--ios-kdd);
}

.company-features {
    margin-bottom: 20px;
    padding: 12px 0;
    border-top: 1px solid var(--ios-medium-gray);
    border-bottom: 1px solid var(--ios-medium-gray);
}

.feature-label {
    font-weight: 500;
    color: var(--ios-text-secondary);
    margin-right: 8px;
}

.feature-content {
    color: var(--ios-text-primary);
}

/* iOS-Style Reaction Buttons */
.reaction-buttons {
    display: flex;
    justify-content: space-around;
    margin-top: 16px;
}

.reaction-button {
    width: 50px;
    height: 50px;
    border-radius: 25px;
    background-color: var(--ios-light-gray);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: var(--ios-text-secondary);
    transition: all 0.2s ease;
}

.reaction-button:active {
    transform: scale(0.95);
    background-color: var(--ios-medium-gray);
}

.like-button.active {
    background-color: var(--ios-success);
    color: white;
}

.dislike-button.active {
    background-color: var(--ios-danger);
    color: white;
}

/* iOS-Style Section Title */
.section-title {
    padding: 16px;
    margin-top: 8px;
}

.section-title h2 {
    font-size: 20px;
    font-weight: 600;
    color: var(--ios-text-primary);
}

/* iOS-Style Comments Container */
.comments-container {
    padding: 0 16px 16px;
}

.comment-item {
    background-color: var(--ios-card);
    border-radius: var(--ios-border-radius);
    padding: 16px;
    margin-bottom: 12px;
    box-shadow: var(--ios-shadow);
}

.comment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.comment-author {
    font-weight: 500;
    color: var(--ios-text-primary);
}

.comment-date {
    font-size: 12px;
    color: var(--ios-text-tertiary);
}

.comment-content {
    color: var(--ios-text-secondary);
    line-height: 1.5;
    margin-bottom: 12px;
}

.comment-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--ios-text-tertiary);
    font-size: 14px;
}

/* iOS-Style Tags */
.tag {
    display: inline-block;
    background-color: var(--ios-light-gray);
    color: var(--ios-text-secondary);
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    margin-right: 6px;
    margin-bottom: 6px;
}

.tag.positive {
    background-color: rgba(52, 199, 89, 0.1);
    color: var(--ios-success);
}

.tag.negative {
    background-color: rgba(255, 59, 48, 0.1);
    color: var(--ios-danger);
}

/* iOS-Style Form Elements Specific to This App */
.dropdown-checkbox {
    width: 100%;
    position: relative;
}

.dropdown-toggle {
    background-color: var(--ios-light-gray);
    border: 1px solid var(--ios-medium-gray);
    border-radius: 10px;
    padding: 12px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.dropdown-toggle span {
    color: var(--ios-text-secondary);
}

.dropdown-arrow {
    color: var(--ios-text-tertiary);
    transition: transform 0.2s ease;
}

.dropdown-checkbox.open .dropdown-arrow {
    transform: rotate(180deg);
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background-color: var(--ios-card);
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    padding: 8px;
    margin-top: 4px;
    z-index: 10;
    max-height: 300px;
    overflow-y: auto;
    display: none;
}

.dropdown-checkbox.open .dropdown-menu {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
}

.checkbox-item {
    padding: 8px;
    display: flex;
    align-items: center;
    border-radius: 8px;
    width: calc(33.33% - 6px);
    box-sizing: border-box;
    margin-bottom: 6px;
}

.checkbox-item:active {
    background-color: var(--ios-light-gray);
}

.checkbox-item input[type="checkbox"] {
    margin-right: 6px;
    width: 18px;
    height: 18px;
    position: relative;
    appearance: none;
    background-color: var(--ios-light-gray);
    border: 1px solid var(--ios-medium-gray);
    border-radius: 4px;
    flex-shrink: 0;
}

.checkbox-item input[type="checkbox"]:checked {
    background-color: var(--ios-kdd);
    border-color: var(--ios-kdd);
}

.checkbox-item input[type="checkbox"]:checked:after {
    content: '';
    position: absolute;
    left: 6px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.checkbox-item label {
    color: var(--ios-text-kdd);
    font-size: 13px;
    flex: 1;
    cursor: pointer;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* iOS-Style Radio Buttons */
.radio-container {
    display: flex;
    width: 100%;
    background-color: var(--ios-light-gray);
    border-radius: 10px;
    overflow: hidden;
    margin: 0 auto;
}

.radio-label {
    flex: 1;
    padding: 8px;
    text-align: center;
    position: relative;
    cursor: pointer;
}

.radio-input {
    position: absolute;
    opacity: 0;
}

.radio-text {
    color: var(--ios-text-secondary);
    font-size: 14px;
    display: block;
    flex-direction: column;
    align-items: center;
}

.radio-text i {
    margin-bottom: 3px;
    font-size: 16px;
}

.radio-input:checked + .radio-custom + .radio-text {
    color: var(--ios-kdd);
    font-weight: 500;
}

/* iOS-Style Login Form */
.login-container {
    padding: 20px;
    max-width: 400px;
    margin: 0 auto;
    padding-top: calc(20px + env(safe-area-inset-top, 0));
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
    padding-top: 20px;
}

.login-header h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--ios-kdd);
}

.login-form {
    background-color: var(--ios-card);
    border-radius: var(--ios-border-radius);
    padding: 20px;
    box-shadow: var(--ios-shadow);
}

.notice-box {
    display: flex;
    align-items: center;
    background-color: rgba(255, 149, 0, 0.1);
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 20px;
}

.notice-box i {
    color: var(--ios-warning);
    font-size: 18px;
    margin-right: 10px;
}

.notice-box p {
    color: var(--ios-text-secondary);
    line-height: 1.4;
}

.input-group {
    position: relative;
    margin-bottom: 16px;
}

.input-icon {
    position: absolute;
    left: 15px;
    top: 22px;
    color: var(--ios-text-tertiary);
    font-size: 16px;
    pointer-events: none;
    z-index: 2;
}

textarea + .input-icon {
    top: 14px;
    transform: none;
}

.auth-input {
    width: 100%;
    padding: 12px 12px 12px 40px;
    border: 1px solid var(--ios-medium-gray);
    border-radius: 10px;
    font-size: 16px;
    background-color: var(--ios-light-gray);
    color: var(--ios-text-primary);
}

.auth-input:focus {
    outline: none;
    border-color: var(--ios-kdd);
    background-color: white;
    box-shadow: 0 0 0 3px rgba(0, 122, 255, 0.1);
}

textarea.auth-input {
    padding: 12px 12px 12px 40px;
    min-height: 100px;
    resize: vertical;
}

.login-btn {
    width: 100%;
    background-color: var(--ios-kdd);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 14px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.login-btn:active {
    background-color: #0062CC;
}

.login-footer {
    text-align: center;
    margin-top: 20px;
}

.login-footer a {
    color: var(--ios-kdd);
    text-decoration: none;
    font-size: 15px;
}

/* Dark Mode Adjustments */
@media (prefers-color-scheme: dark) {
    .top-nav {
        background-color: rgba(28, 28, 30, 0.95);
    }
    
    .notice-box {
        background-color: rgba(255, 149, 0, 0.15);
    }
    
    .tag.positive {
        background-color: rgba(52, 199, 89, 0.15);
    }
    
    .tag.negative {
        background-color: rgba(255, 59, 48, 0.15);
    }
} 