automation:
  - alias: Lighting · Turn on ceiling lights after sunset
    trigger:
      platform: sun
      event: sunset
      offset: "-00:30:00"
    condition:
      - condition: state
        entity_id: binary_sensor.someone_home
        state: "on"
    action:
      - service: light.turn_on
        entity_id: light.on_after_dark
        data:
          brightness_pct: 100
      - service: logbook.log
        data:
          name: "💡 Lighting Module · "
          message: "Lights On · 30 mins to sunset"
          domain: light

  - alias: Lighting · Turn off all lights after sunrise
    trigger:
      platform: sun
      event: sunrise
      offset: "+00:00:00"
    action:
      - service: script.turn_off_all_lights
